Answers for "python how to repeat an event every n seconds"

2

python repeat every n seconds

#executes printit() every 5s
import threading
def printit():
  threading.Timer(5.0, printit).start()
  print "Hello, World!"

printit()
Posted by: Guest on March-07-2021

Code answers related to "python how to repeat an event every n seconds"

Python Answers by Framework

Browse Popular Code Answers by Language