📜  python datetime add - Python 代码示例

📅  最后修改于: 2022-03-11 14:47:22.999000             🧑  作者: Mango

代码示例2
import datetime
delta = datetime.timedelta(
     days=50,
     seconds=27,
     microseconds=10,
     milliseconds=29000,
     minutes=5,
     hours=8,
     weeks=2
)

new_datetime = datetime.now() + delta