My problem is that when I include a space before / after inputting a string (such as a customer's name, or an item's name), it doesn't read it properly. I use the standard std::cin to handle any numbers the user inputs, and std::getline() for any string they enter. The usual case is that the user has to either enter a number, or type in a string. My program (reward system that deals with customers/items) involves getting input from the user multiple times.
0 Comments
Leave a Reply. |