python time sleep

Asked 2 years ago, Updated 2 years ago, 16 views

time.I hung a sleep (7200)

After two hours, the code below should work, but it doesn't seem to work.

Why is that?

time.Except for sleep (7200) , if you turn the code, it turns around, but it's probably Sleep (7200) seems to be the problem.

time.Will it be solved if I cut sleep in short units?

python

2022-09-20 15:52

1 Answers

two hours in the eyes and see if he's taking a breath and try to what will.

time.You can test sleep() itself with this code. Would you like to check?

import datetime

print("down")
print(datetime.datetime.now())
sleep(7200)
print("up")
print(datetime.datetime.now())


2022-09-20 15:52

If you have any answers or tips


© 2024 OneMinuteCode. All rights reserved.