提交 71b6001a 编写于 作者: H hjdhnx

test

上级 47d40839
#!/usr/bin/env python3
# -*- coding: utf-8 -*-
# File : test_time.py
# Author: DaShenHan&道长-----先苦后甜,任凭晚风拂柳颜------
# Date : 2022/12/29
import datetime
from datetime import timedelta
if __name__ == '__main__':
# a = datetime.datetime.now().now().replace(hour=0, minute=1)).strftime('%Y-%m-%d %H:%M:%S')
# print(a)
print(datetime)
print(datetime.datetime.now())
print(datetime.datetime.now().replace(hour=0, minute=1).strftime('%Y-%m-%d %H:%M:%S'))
print((datetime.datetime.now().replace(hour=0, minute=0, second=0)+ timedelta(days=1)).strftime('%Y-%m-%d %H:%M:%S'))
\ No newline at end of file
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册