python-scripts/Digital-Clock/Sourodip20kar.md
2022-10-04 23:15:52 +05:30

639 B

Digital Clock

code

import tkinter
from time import strftime

top = tkinter.Tk()
top.title('Digital Clock')
top.resizable(0,0)

def time():
    string = strftime('%H: %M: %S %p')
    clockTime.config(text=string)
    clockTime.after(1000, time)

clockTime = tkinter.Label(top, font=('courier new', 40),
background='white',foreground='black')
clockTime.pack(anchor='center')
time()
top.mainloop()

Screenshot 2022-10-04 195233

ISSSUE

https://github.com/metafy-social/daily-python-scripts/issues/128#issue-1396619270