Skip to content

Instantly share code, notes, and snippets.

@Echocage
Created September 26, 2014 00:12
Show Gist options
  • Save Echocage/3c8e561a651d7675ce65 to your computer and use it in GitHub Desktop.
Save Echocage/3c8e561a651d7675ce65 to your computer and use it in GitHub Desktop.
import datetime
import time
while True:
with open('filename.txt', 'w+') as output:
now = datetime.datetime.now().time().strftime('%I:%M:%S')
output.write(now)
time.sleep(1)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment