User Input | Sololearn: Learn to code for FREE!


User Input

How is user input(multiple) used practically? How to type Type Multiple User inputs?

6/18/2018 8:13:59 AM


4 Answers

New Answer



assuming you mean how to get multiple input in c++ . just use cin or scanf.wherever you need inputs,it will not work here on code playground so try in your pc


let's say you have 2 variables, "a" and "b". you want to read their input in one line(or different lines). you would do: cin >> a >> b


cin >> /* a variable */ a >> /* a variable */ b ; You can also do like this