暂停一秒输出,并格式化当前时间。

import time
print( time.strftime("%Y-%m-%d %H:%M:%S"),time.localtime())
time.sleep(1)
print( time.strftime("%Y-%m-%d %H:%M:%S"),time.localtime())
发布了44 篇原创文章 · 获赞 1 · 访问量 1373

猜你喜欢

转载自blog.csdn.net/cc_park/article/details/104341082
今日推荐