0

Eof error

why im i getting an eof error on the sololearn app when i run this code but on the pc it kinda loops till i end the program https://code.sololearn.com/cznypLMEPq05/?ref=app

16th Aug 2017, 5:40 PM
kalooh Kennedy
kalooh Kennedy - avatar
7 ответов
+ 5
Here you go. So your inputs will be: 45 {enter} 90 {enter} 0 {enter} end https://code.sololearn.com/cP3J3uWFeDHN/?ref=app
16th Aug 2017, 6:19 PM
Limitless
Limitless - avatar
+ 4
So your program has a while(true) loop. On desktop you can get multiple inputs only by pressing enter. But on Sololearn you need to tell your program to only get a certain amount of inputs because it does not like looping forever. On Sololearn it works like this: Yoi send it one request, and it send one piece of data back, end. On your computer: You send one request, it sends one piece of data back, then it waits for another request.
16th Aug 2017, 6:10 PM
Limitless
Limitless - avatar
+ 4
Give it a ✔ if you're happy 😉
16th Aug 2017, 6:56 PM
Limitless
Limitless - avatar
+ 3
You'll need to make an if statement that checks a specific input.
16th Aug 2017, 6:13 PM
Limitless
Limitless - avatar
+ 1
thanks limitless 👍👍
16th Aug 2017, 6:24 PM
kalooh Kennedy
kalooh Kennedy - avatar
+ 1
sure ✔✔✔ hehe
16th Aug 2017, 7:01 PM
kalooh Kennedy
kalooh Kennedy - avatar
0
thanks, so how do i make sololearn loop until i want it to stop?
16th Aug 2017, 6:12 PM
kalooh Kennedy
kalooh Kennedy - avatar