Compare commits

...

1 Commits
master ... main

Author SHA1 Message Date
chenyh dc6c7d4f77 ADD file via upload 2023-07-11 09:30:00 +08:00
1 changed files with 10 additions and 0 deletions

10
main.py Normal file
View File

@ -0,0 +1,10 @@
import date
import time
# 定义原始时间格式字符串和目标时间格式字符串
raw_time_str = "2023-05-04T00:00:00.000+08:00"
target_time_str = "2023-05-03T16:00:00.000Z"
local_time = time.localtime(time.time() - time.ctime(raw_time_str))
date.parse(raw_time_str).strftime(target_time_str, time.strftime("%Y-%m-%dT%H:%M:%S.%fZ"))