User input (cin) problem in Sololearn. | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 1

User input (cin) problem in Sololearn.

I write a code and i occured a problem. when using sololearn, before the code run, sololearn want user input. so how i can take user input ONLY each time loop start again in sololearn not in start of program? the program run without problem when i run it in my pc. https://code.sololearn.com/c6lHamjinEdI/#cpp

23rd Nov 2018, 5:22 AM
Abolhasan Ashori
Abolhasan Ashori - avatar
1 Answer
+ 3
This is a limitation of Code Playground. All input has to be received before the code is sent to the server for compilation. Just do according to the steps listed by the input box. Split multiple input into different lines. E.g. std::cin >> a >> b; Input: 3 9
23rd Nov 2018, 5:27 AM
Hatsy Rei
Hatsy Rei - avatar