Created
December 8, 2020 08:46
-
-
Save mtovmassian/0ab2672cef0e98d11090e711c782a134 to your computer and use it in GitHub Desktop.
Continuous display of time
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/python3 | |
from datetime import datetime | |
from time import sleep | |
while True: | |
time_ = datetime.now().strftime("%H:%M:%S:%f")[:-3] | |
print(f"\r{time_}", end="") | |
sleep(0.1) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment