Subject: C
From: david wright (dwright5@nyc.rr.com)
Date: Wed Jan 16 2002 - 20:09:43 MST
Well, i guess i'll turn to my trusty old YDL masters! I have been trying to
find an archive (html) of the comp.lang.c usenets postings, so i can browse
quickly through past and present postings, wihtout having to read through the
individual 'news style' daily's. (such as http://archive.develooper.com/ is
for perl)
My question is actually a simple one, but i can't seem to find a place to ask
it. I have seen this simple program output the same results, from the same
compilier.
--------------------- example #1
# include <stdio.h>
int main (void)
{
printf ("whatever\n");
return 0;
}
--------------------- example #2
# include <stdio.h>
main(){
printf ("whatever\n");
}
----------------------
Is this a matter of ASCI II standards? (#1 being more recent)
I know that you have to declare variable types. i.e. int x, y; but declare
functions, or just the main function? and (void).
I have heard of return 0 as being unecessary for todays standards?
I can see that the formatting of #2 is just a matter of taste.
Please excuse my temporary YDL excursion. Thanks again
-david
This archive was generated by hypermail 2a24 : Wed Jan 16 2002 - 20:22:56 MST