赞
踩
time = datetime.datetime.now().strftime("%Y-%m-%d %H:%M:%S") # 获取当前系统时间,返回年月日时分秒 print(time)
结果样例
2022-08-21 18:28:24