【发布时间】:2012-12-30 23:46:55
【问题描述】:
这是我的代码
while x <= datetime.date.today():
print something
我怎样才能得到datetime.date.tomorrow() ?
【问题讨论】:
这是我的代码
while x <= datetime.date.today():
print something
我怎样才能得到datetime.date.tomorrow() ?
【问题讨论】:
tomorrow = datetime.date.today() + datetime.timedelta(days=1)
将date() 和timedelta() 相加时,仅使用.days 属性。
【讨论】: