- 1
Time
How do I send a message every night? #Python3
1 Odpowiedź
0
You can import datetime and use it like this:
from datetime import datetime
now = datetime.now()
current_time = now.strftime("%H:%M:%S")
if curren_time == "23:0:0"
print("Good night!")
It print every night at 23:00 a message. I wish this example help you