+ 1

Code gives EOF error in Playground

Hello! My code can be found here: https://code.sololearn.com/ccxHBuJe4RWx The problem is that when i enter any number in the items my code gives me the following error: Traceback (most recent call last): File "./Playground/file0.py", line 6, in <module> item = input("Ok, tell me what to add in the list!\n") EOFError: EOF when reading a line If i run it on other editors ( onlinegdb.com or repl.it ) it seems to run fine! I cannot spot any errors in the code, so i am wondering. Have i stumbled on a Code Playground bug? If so i thought it would be reported to the mod team up to now since the code i am running is basic at best.

18th Feb 2020, 9:38 AM
Theofanis Vavilis
Theofanis Vavilis - avatar
3 Réponses
+ 4
it's a limitation of Playground, you have to write all inputs at once each one in new line. it's not interactive. it doesn't wait for while loop each time. try : 2 apples oranges then submit
18th Feb 2020, 9:43 AM
Bahhaⵣ
Bahhaⵣ - avatar
+ 2
Thank you, this clears the confusion. I might have missed it, but it would be beneficial for new learners to add a note when Code Playground is introduced - while the prompt makes sense, it does so retrospectively.
18th Feb 2020, 9:54 AM
Theofanis Vavilis
Theofanis Vavilis - avatar