帮我写个时钟用python
下面是一个简单的Python时钟程序:
import time
while True:
current_time = time.strftime('%H:%M:%S')
print(current_time)
time.sleep(1)
这个程序将会不断输出当前时间,每秒钟输出一次。你可以按Ctrl+C来结束程序。
原文地址: https://www.cveoy.top/t/topic/bCUY 著作权归作者所有。请勿转载和采集!
安全问答是一个知识全球问答,包含丰富的问答知识
下面是一个简单的Python时钟程序:
import time
while True:
current_time = time.strftime('%H:%M:%S')
print(current_time)
time.sleep(1)
这个程序将会不断输出当前时间,每秒钟输出一次。你可以按Ctrl+C来结束程序。
原文地址: https://www.cveoy.top/t/topic/bCUY 著作权归作者所有。请勿转载和采集!