The ‘
time
’ module
The following are a few simple methods from the time model. There is much more
functionality in this module, and in the related datetime module, e.g. for time string
representation, formatting and daylight savings, which is described in the standard on-line
Python documentation.
Method
(time.)
Description
ctime(secs)
Generates a human-readable string from a time represented in
seconds (since the arbitrary zero time: 00:00:00 UTC on 1 January
1970) . Defaults to the current time if no argument is specified.
sleep(secs)
Suspends the execution of the program for a given number of
seconds.
time()
Retrieves the time in seconds since the system zero time (00:00:00
UTC on 1 January 1970).
Do'stlaringiz bilan baham: |