Say I have,
1 2 3 4 5 6 7 8
|
using std::string;
string temp_id;
string temp_name;
std::cout << "ID\n> ";
std::cin >> temp_id;
std::cout << "Name\n> ";
std::cin >> temp_name;
|
If user simply taps
ENTER
for either value, how can I store that as an empty string? I keep tapping enter, and it keeps expecting characters.
Last edited on