candide said:
I don't think it says so in exactly those words (and if it does, I'd argue
that it's wrong). Certainly I can't find such wording on a cursory look
through that section.
Okay, here's the whole thing.
There exists an array of char *. Zero (or more, but exactly argc) members
of that array each point to the first character of a string that
represents a command line argument. The next member, the [argc] member, is
guaranteed to be NULL.
argv, as received by main, is a pointer to the first element in that array.
--
Richard Heathfield <http://www.cpax.org.uk >
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
Hi,
>
K&R2 §5.10 tells that the second parameter to the main function,
usually called argv, has type pointer to character strings.
>
K&R2 §5.10 tells that the second parameter to the main function,
usually called argv, has type pointer to character strings.
that it's wrong). Certainly I can't find such wording on a cursory look
through that section.
Okay, here's the whole thing.
There exists an array of char *. Zero (or more, but exactly argc) members
of that array each point to the first character of a string that
represents a command line argument. The next member, the [argc] member, is
guaranteed to be NULL.
argv, as received by main, is a pointer to the first element in that array.
--
Richard Heathfield <http://www.cpax.org.uk >
Email: -http://www. +rjh@
Google users: <http://www.cpax.org.uk/prg/writings/googly.php>
"Usenet is a strange place" - dmr 29 July 1999
Comment