获取当前系统时间

import time

print(time.strftime('%Y/%m/%d %H:%M:%S', time.localtime()))
# 2022/06/27 20:55:56

 

posted @ 2022-06-27 20:58  xuecl  阅读(13)  评论(0编辑  收藏  举报