Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR PYTHON

how to run a function in interval in python

# this makes program sleep in intervals
from time import time, sleep
while True:
    sleep(1 - time() % 1) # run every 1 second... you can change that
	# thing to run
 
PREVIOUS NEXT
Tagged: #run #function #interval #python
ADD COMMENT
Topic
Name
3+6 =