Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- from time import sleep
- hours = 0
- minutes = 0
- seconds = 0
- while True:
- if seconds == 60:
- minutes += 1
- seconds = 0
- if minutes == 60:
- hours += 1
- minutes = 0
- print("{:02d}:{:02d}:{:02d}".format(hours, minutes, seconds), end='\r')
- sleep(1)
- seconds += 1
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement