How to use ' cin >>' function? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

How to use ' cin >>' function?

Give some examples.

25th Sep 2018, 9:29 AM
NIGHT STAR
NIGHT STAR - avatar
2 Answers
+ 5
string x; cin >> x; It saves entered text to variable x. You can input multiple values too: cin >> x >> y;
25th Sep 2018, 9:33 AM
Aleksander Szczepura
Aleksander Szczepura - avatar
0
As I know cin is OBJECT, not a function.
25th Sep 2018, 10:13 AM
Mustafa K.
Mustafa K. - avatar