I've never done this, but it doesn't look you passed any arguments
You are right. he has just called the program without any command line argument.
Also, you answered it rightly to him.
As a matter of explanation: the system() function takes a Cstring and pass it to the command prompt( or terminal or shell for Linux user) and then returns a value which is platform dependent.
So, while using system(), assume as if you were typing everything at the command prompt.
So, the correct thing as daviddoria said, will be: system("FileName.exe arg1 arg2"); Also this is even good:
getline(std::cin,s1);//take command from user
system(s1.c_str());//pass it to the shell
I am working creating a fully encapsulated, homogeneous singly linked data structure. The Listing class and SinglyLinkedList class that are part of the whole application compile fine, but the problem ...