How to pause execution for 5 seconds in Python

1 Answer

0 votes
import time

print("Execution paused for 5 seconds...")

# Pause execution for 5 seconds
time.sleep(5)

print("Resuming execution.")



'''
run:

Execution paused for 5 seconds...
Loop finished.

'''

 



answered Apr 30 by avibootz

Related questions

1 answer 40 views
2 answers 47 views
1 answer 31 views
1 answer 36 views
1 answer 40 views
...