cin does not wait for input

Solutions on MaxInterview for cin does not wait for input by the best coders in the world

showing results for - "cin does not wait for input"
Sara
01 Aug 2017
1/* cin stops taking input on whitespace encounter
2* so if you pass "Prakhar Patel" into cin>>name;
3* only "Prakhar" will be stored into name.
4* "Patel" will stay in stream and will come into next cin statement.
5*/
6
7getline(cin,fullname,'\n'); //use this to capture input stream till \n