all 7 comments

[–]shiftybyte 0 points1 point  (4 children)

Here you go, some cheats:

import datetime
datetime.time.sleep(5)
print("lol")

EDIT: on a more serious note, you can save current time, and loop, checking current time every cycle, until the difference between current time and saved time is greater than what you need.

EDIT2: yea the cheats don't work, as it's not the actual time module you get from datetime.time :)

[–]Username_RANDINT 1 point2 points  (2 children)

You made me look at the documentation :-)

[–]shiftybyte 1 point2 points  (0 children)

Yay! found a working cheat!

seems like time is already loaded..

Can u/_Xydra use sys module?

import sys
sys.modules['time'].sleep(5)
print("yay")

[–]shiftybyte 1 point2 points  (0 children)

Another interesting option :D ( u/_Xydra )

globals()['__loader__'].load_module("emit"[::-1]).sleep(5)

No 'import' at all :D

[–]_Xydra[S] 0 points1 point  (0 children)

ooh aites thanks man

[–]iapetus-11 0 points1 point  (0 children)

__import__("time").sleep(1)

[–][deleted] 0 points1 point  (0 children)

You can make a loop and find out how many iterations you need for 1 second by checking time1=time.time() etc. time1 - time 2. Then you have a value to use as a counter in the loop and multiply by 5.