0

Is it possible to have more than one cin input?

wrote a program with multiple "cin", but if I start it, it just gets to the first input and then skips the other 3.

25th Nov 2016, 5:18 PM
Julian Gegner
Julian Gegner - avatar
1 Antwort
+ 2
yes for example if you declare 3 variables and you want to scan a value for those ones, the normal form is: int a,b,c; cin>>a; cin>>b; cin>>c; //but the short version of this is the next one: cin>>a>>b>>c;
25th Nov 2016, 5:42 PM
Alberto c
Alberto c - avatar