Hi. I am doing unix systems programming and was wondering if it is possible to do it in Microsoft Visual C++. Everything should work.. except there is one problem.. reading in arguments... here is an easy program:
#include <stdio.h>
int main ( int argc, char ** argv )
{
int i;
printf ( "The number of arguments (argc) is %d.\n", argc );
printf ( "The contents of the argument vector (argv) is:\n" );
for ( i = 0; i < argc; i++ )
printf( "argv[ %d ] = %s\n", i, argv[ i ] );
return 0;
}
this just prints out all the arguments... in unix it runs perfect since it has a command line.. but how could i enter the arguments in vs c++?? I just like the vs c++ error detection better.. its easier for me to read and understand. Thanks!
Question
saiz66
Hi. I am doing unix systems programming and was wondering if it is possible to do it in Microsoft Visual C++. Everything should work.. except there is one problem.. reading in arguments... here is an easy program:
#include <stdio.h>
int main ( int argc, char ** argv )
{
int i;
printf ( "The number of arguments (argc) is %d.\n", argc );
printf ( "The contents of the argument vector (argv) is:\n" );
for ( i = 0; i < argc; i++ )
printf( "argv[ %d ] = %s\n", i, argv[ i ] );
return 0;
}
this just prints out all the arguments... in unix it runs perfect since it has a command line.. but how could i enter the arguments in vs c++?? I just like the vs c++ error detection better.. its easier for me to read and understand. Thanks!
Link to comment
Share on other sites
5 answers to this question
Recommended Posts