+ 1

This code runs perfectly on Pydroid but gives me an eof error here - thanks for your input

https://code.sololearn.com/cpi4kzhQ8JDq/?ref=app

22nd Apr 2018, 7:41 PM
Johannes
Johannes - avatar
6 Answers
+ 3
You don't even prompt it. On Code Playground when you run a program and it needs an input at some point the system asks you for it right when you click run
22nd Apr 2018, 8:05 PM
cyk
cyk - avatar
+ 2
cyk Markus Kaleton How can I prompt for input before the code runs if the input is part of the program?
22nd Apr 2018, 7:55 PM
Johannes
Johannes - avatar
+ 2
Thanks cyk - basically, it's a limitation of the ide they use (similar to Sublime text editor, on Mac OS at least). Thanks for clarifying!
22nd Apr 2018, 8:10 PM
Johannes
Johannes - avatar
+ 1
Are you getting input from the user while the code is running? If so, you will get an EOF error here cause in Code Playground the user cannot feed the program inputs while it is running, only once at the beginning
22nd Apr 2018, 7:49 PM
cyk
cyk - avatar
+ 1
you have to submit your inputs before the code runs. this kind of test isnt really suited for sololearn
22nd Apr 2018, 7:50 PM
Markus Kaleton
Markus Kaleton - avatar
+ 1
I did run it with 4 as input at the beginning and it worked fine
22nd Apr 2018, 7:50 PM
cyk
cyk - avatar