how to run a function at a specific time in python

0

How can I execute a function of a python script every certain hour? This is what I have so far:

import sched
import time

def saludar():
    print("hola")

programador = sched.scheduler()
programador.enterabs(time, 1, saludar())
programador.run()

For example, I want it to run, for example, at 3:00 p.m. and 6:00 p.m. after executing the script.

    
asked by Mystic_Force 10.08.2018 в 04:50
source

0 answers