48 lines
1016 B
Python
Executable File
48 lines
1016 B
Python
Executable File
from turtle import*
|
|
import datetime
|
|
import time
|
|
|
|
style = ("Minecraftia", 75, "normal")
|
|
tracer(0)
|
|
|
|
#Ausführen der Uhr.
|
|
while True:
|
|
time.sleep(1)
|
|
clear()
|
|
ht()
|
|
pu()
|
|
sec = datetime.datetime.now().second
|
|
min = datetime.datetime.now().minute
|
|
h = datetime.datetime.now().hour
|
|
bk(350)
|
|
#Abstände definieren
|
|
if h >= 10:
|
|
write(h, font=style)
|
|
fd(200)
|
|
else:
|
|
write("0", font=style)
|
|
fd(100)
|
|
write(h, font=style)
|
|
fd(100)
|
|
write(":", font=style, align = "left")
|
|
fd(50)
|
|
if min >= 10:
|
|
write(min, font=style)
|
|
fd(200)
|
|
else:
|
|
write("0", font=style)
|
|
fd(100)
|
|
write(min, font=style)
|
|
fd(100)
|
|
write(":", font=style, align = "left")
|
|
fd(50)
|
|
if sec >= 10:
|
|
write(sec, font=style)
|
|
fd(200)
|
|
else:
|
|
write("0", font=style)
|
|
fd(100)
|
|
write(sec, font=style)
|
|
fd(100)
|
|
home()
|
|
update() |