+ 4
What is the difference between getchar () and getline () ?
And cin when we read line ?
1 Antwort
+ 1
This is a good answer for the gets:
https://www.daniweb.com/programming/software-development/threads/444375/getline-vs-getchar
string s;
cin >> s;
Only reads to the first whitespace character so words from the line.