I had a chance to look at the codes of some (small-time) professional software, written in C++.
In almost all the main() functions there are these two parameters. Like
1 2 3 4
int main(int *argc, char *argv[])
{
//...
}
Also, had a look at a few tutorials on programming with GTK+ and QT etc etc, and they have the same trend there... I was under the impression that these might be the pointers to the containers which hold the command line arguments like switches and options... But I am not sure. (Although I use that line for style, :P... A simple int main() looks way less fashionable.)
First parameter (which is of type int, not int*) contains the number of elements in the second one, which is an array of C strings containing the program arguments (first is the program name, though).