内容简介:Python time time() 返回当前时间的时间戳(1970纪元后经过的浮点秒数)。
描述
Python time time() 返回当前时间的时间戳(1970纪元后经过的浮点秒数)。
语法
time()方法语法:
time.time()
参数
- NA。
返回值
返回当前时间的时间戳(1970纪元后经过的浮点秒数)。
实例
以下实例展示了 time() 函数的使用方法:
#!/usr/bin/python import time print "time.time(): %f " % time.time() print time.localtime( time.time() ) print time.asctime( time.localtime(time.time()) )
以上实例输出结果为:
time.time(): 1234892919.655932 (2009, 2, 17, 10, 48, 39, 1, 48, 0) Tue Feb 17 10:48:39 2009
以上就是本文的全部内容,希望对大家的学习有所帮助,也希望大家多多支持 码农网
本站部分资源来源于网络,本站转载出于传递更多信息之目的,版权归原作者或者来源机构所有,如转载稿涉及版权问题,请联系我们。
A Project Guide to UX Design
Russ Unger、Carolyn Chandler / New Riders Press / 2009-3-23 / USD 39.99
"If you are a young designer entering or contemplating entering the UX field this is a canonical book. If you are an organization that really needs to start grokking UX this book is also for you. " -......一起来看看 《A Project Guide to UX Design》 这本书的介绍吧!