-
Think about it this way: argc is an int given to your program representing the number of command line arguments (including the program name). Thus for foo bar bas, argc = 3. argv, on the other hand, is a character array representing the arguments themselves. Thus, argv[0] is your program's name. For foo bar bas, argv[0] = "foo", argv[1] = "bar", and argv[2] = "bas". When VC++ compiles your program, it by default provides no arguments. Thus your program recognizes this and quits.
-
karlawarla: are you studying at University of Westminster?;p
-
-
manutd, thank you for your post, i'll take note. :-)
-
karlawarla: ye, Internet Computing course;p
-
kool, i'm doing the visualisation course, but taken programming methodology as my free choice, hence all the c++ questions lol