发布时间:2019-07-15 10:49:39编辑:auto阅读(1498)
def print_drict():
ticks = time.time()
print ticks
print '===================='
locatime = time.asctime(time.localtime(time.time()))
print locatime
i = datetime.datetime.now()
print (u"当前的日期和时间是 %s" % i)
print (u"ISO格式的日期和时间是 %s" % i.isoformat())
print (u"当前的年份是 %s" % i.year)
print (u"当前的月份是 %s" % i.month)
print (u"当前的日期是 %s" % i.day)
print (u"dd/mm/yyyy 格式是 %s/%s/%s" % (i.day, i.month, i.year))
print (u"当前小时是 %s" % i.hour)
print (u"当前分钟是 %s" % i.minute)
print (u"当前秒是 %s" % i.second)
print_drict()
上一篇: Python程序--hello worl
下一篇: python virtualenv开发环
47483
45786
36783
34310
28955
25589
24436
19606
19096
17626
5458°
6041°
5557°
5632°
6558°
5370°
5370°
5877°
5850°
7163°