Hi - I'm doing the same uni project as warny_maelstrom. Interesting thread that... anywho - I've been going through the faq's trying to get my head around this - seeing as a chunk of code was dumped in warny's thread im a little behind, i couldn't start from the beginning. I'm looking at the faq
http://faq.cprogramming.com/cgi-bin/...&id=1043284392
and in the first example there are arguments passed into the main function...
As most will know, i'm a little new and a little inquisitive. So if anyone can answer my question - are you allowed to do this and if so, what purpose would you do so under?Code:int main ( int argc, char *argv[] ) { int ch; FILE *in; FILE *out; if ( argc != 3 ) { fprintf ( stderr, "Usage: %s <readfile1> <writefile2>\n", argv[0] ); exit ( EXIT_FAILURE ); } ... ... ...
Cheers, and expect more soon
Mitch



LinkBack URL
About LinkBacks



