Quote Originally Posted by robwhit View Post
http://www.cplusplus.com/reference/c...dio/fgets.html or just do
Code:
scanf("%s %s %s\n", command, arg1, arg2);
I think this may not work as well as strtok because it requires 3 strings to be input and needs termination after each string. If the user enters <exit> and nothing else, this scanf function will just sit there waiting for more input.
I need to do a single line input and then parse it into three different string arrays. I will try fgets and see how that works out for me.