Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR CPP

getline(cin string) not working

//Using cin.clear() to ignore any trailing newline character
string str;
cin.clear();
getline(cin, str);
 
PREVIOUS NEXT
Tagged: #working
ADD COMMENT
Topic
Name
3+8 =