Why does .sleep() not work on the code playground? | Sololearn: Learn to code for FREE!
New course! Every coder should learn Generative AI!
Try a free lesson
+ 3

Why does .sleep() not work on the code playground?

Hey guys, I tried this: from time import sleep print(" Hey, Wake Up!") sleep(1) print(" zzz...") But it doesnt work here. Hey, Wake Up! and zzz.... appear in the same moment. What can I do here to create a delay, if .sleep() doesnt work or is it just me?

7th Feb 2017, 2:03 PM
Bengi
Bengi - avatar
4 Answers
+ 9
Sololearn's Code Playground is not the best friend writing complex programs. For better results, get Python from www.python.org
7th Feb 2017, 2:11 PM
Caleb Jore
Caleb Jore - avatar
+ 9
Sorry, I didn't mean 'friend' I meant 'for'
7th Feb 2017, 2:14 PM
Caleb Jore
Caleb Jore - avatar
+ 5
Code Playground have at least one important limitation in handling in/output... The script is executed on server side, so you are restricted to uninterractive script ( which doesn't require real time user interation ), as ALL inputs must be send at once just before executing script, and output are received only at once just after the script end ^^
8th Feb 2017, 9:08 AM
visph
visph - avatar
0
alright thank you :)
7th Feb 2017, 2:14 PM
Bengi
Bengi - avatar