..... Don't know how to delete this thread
Printable View
..... Don't know how to delete this thread
What do you mean by "the terminal opens"?
This isn't right. There's something missing.Code:getName()
The file stream variable is defined as dataIn, but you use inData to open the file??Code:ifstream dataIn;
...
inData.open("data.txt");
Where is the variable remove defined?Code:remove = name.find(",");
What is meant by using .sub()? Your problem states to use substr()!Code:lastName = name.sub(0, remove);