Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
| From | Keith Thompson <kst-u@mib.org> |
|---|---|
| Newsgroups | comp.lang.c |
| Subject | Re: what is the output? |
| Date | 2011-07-04 14:33 -0700 |
| Organization | None to speak of |
| Message-ID | <ln39il4tpu.fsf@nuthaus.mib.org> (permalink) |
| References | <080abbae-9aea-4c3e-a504-9ac1b3e01af1@glegroupsg2000goo.googlegroups.com> <1b1uy7i0v1.fsf@snowball.wb.pfeifferfamily.net> <fd8edf90-9baa-4b0a-a8ef-30b05fe0004c@g12g2000yqd.googlegroups.com> <87vcvio6pr.fsf@temporary-address.org.uk> |
Dr Nick <3-nospam@temporary-address.org.uk> writes:
> Hans Vlems <hvlems@freenet.de> writes:
>> On 3 jul, 22:08, Joe Pfeiffer <pfeif...@cs.nmsu.edu> wrote:
>>> vinay kumar <vinay...@gmail.com> writes:
>>> > main()
>>> > {
>>> > int d=010;
>>> > printf("%d",d);
>>> > }
>>>
>>> I don't want to be too rude, but you could compile and run it and find
>>> the output for yourself much faster than you can expect an answer here.
>>
>> My guess is that the OP did do that. And it failed to compile because
>> printf
>> wasn't defined. If the OP had managed to find the answer to that in
>> his textbook then the
>> question would never have arrived here.
>> I seriously doubt the OP is interested in niceties as main() vs.
>> main(void) or int main(void).
>
> My guess is he didn't. My guess is it's our resident troll again.
> Let's count shall we:
>
> no #includes
> no type for main
> no void
> no trailing newline on printf
> no return from main
>
> 5 out of 5.
>
> That's ignoring the actual problem of course.
My guess is that it's simply old code. IIRC, 4 out of 5 of the
things you count are characteristics of the "hello world" program
in K&R1.
--
Keith Thompson (The_Other_Keith) kst-u@mib.org <http://www.ghoti.net/~kst>
Nokia
"We must do something. This is something. Therefore, we must do this."
-- Antony Jay and Jonathan Lynn, "Yes Minister"
Back to comp.lang.c | Previous | Next — Previous in thread | Next in thread | Find similar | Unroll thread
what is the output? vinay kumar <vinay5b9@gmail.com> - 2011-07-03 09:34 -0700
Re: what is the output? "osmium" <r124c4u102@comcast.net> - 2011-07-03 11:57 -0500
Re: what is the output? Vincenzo Mercuri <vincenzo.mercuri@yahoo.it> - 2011-07-03 19:05 +0200
Re: what is the output? Vincenzo Mercuri <vincenzo.mercuri@yahoo.it> - 2011-07-03 19:18 +0200
Re: what is the output? Vincenzo Mercuri <vincenzo.mercuri@yahoo.it> - 2011-07-03 19:22 +0200
Re: what is the output? Geoff <geoff@invalid.invalid> - 2011-07-03 12:31 -0700
Re: what is the output? Joe Pfeiffer <pfeiffer@cs.nmsu.edu> - 2011-07-03 14:08 -0600
Re: what is the output? Hans Vlems <hvlems@freenet.de> - 2011-07-03 23:33 -0700
Re: what is the output? Dr Nick <3-nospam@temporary-address.org.uk> - 2011-07-04 08:17 +0100
Re: what is the output? Keith Thompson <kst-u@mib.org> - 2011-07-04 14:33 -0700
Re: what is the output? James Kuyper <jameskuyper@verizon.net> - 2011-07-04 19:14 -0400
Re: what is the output? Chad <cdalten@gmail.com> - 2011-07-05 10:59 -0700
Re: what is the output? Keith Thompson <kst-u@mib.org> - 2011-07-05 11:18 -0700
Re: what is the output? Todd Carnes <toddcarnes@gmail.com> - 2011-07-05 18:23 +0000
Re: what is the output? James Kuyper <jameskuyper@verizon.net> - 2011-07-05 23:00 -0400
Re: what is the output? Joe Pfeiffer <pfeiffer@cs.nmsu.edu> - 2011-07-04 07:25 -0600
Re: what is the output? Willem <willem@turtle.stack.nl> - 2011-07-04 15:11 +0000
Re: what is the output? Phil Carmody <thefatphil_demunged@yahoo.co.uk> - 2011-07-07 17:33 +0300
csiph-web