+ 1

How do i make my c++ code in sololearn ask for values in my while loop one by one.

Codes in while loop in c++ just asks for values.. And do not ask for values again.. Instead they just repeat the values you put there.. Please how do i fix this.. Because in microsoft visual studio.. Its not like this.

8th Oct 2020, 6:10 PM
Uyi Oduware
Uyi Oduware - avatar
4 Antworten
+ 4
sololearn accepts all the inputs first time only ,it's not interactive like any other ide
8th Oct 2020, 6:14 PM
Abhay
Abhay - avatar
+ 1
Thank you abhay
8th Oct 2020, 6:49 PM
Uyi Oduware
Uyi Oduware - avatar
+ 1
while loop continue to iterate until the given condition become false. E.g. while (x!="stop") { x=cin>>; }
8th Oct 2020, 7:46 PM
Shadoff
Shadoff - avatar
+ 1
Avalon the OP was looking for a way to do this in realtime in SoloLearn which is not possible as all input needs to be provided before the program executes. Given they said SoloLearn isn't working the way it does in Visual Studio, it is safe to conclude that they already know how to request input within a loop.
8th Oct 2020, 8:20 PM
MaddieL
MaddieL - avatar