0
上午9点unix时间戳如果我想知道系统的第二天上午9点的时间戳,获取蟒蛇
可能有两种情况:
1. If the current time is 11 P.M of 2013-11-05 and I want to get the timestamp for 9 A.M 2013-11-06
2. If the current time is 2 A.M for 2013-11-06 and I need the timestamp for 9 A.M for same day
有没有更好的方式来处理这或我分别计算我的小时,日,月,年,然后生成一个我试图避免的日期时间对象。
如果当前时间是上午11点,然后添加datetime.timedelta(小时= 24)会给我第二天11 AM – jdk2588
@ jdk2588的时间,但随后设置时间值将使第二天的上午9点这正是什么你问了。 –
是啊!正确的感谢 – jdk2588