Att Time Sleep
# Python2.x Python time sleep() Method
* * *
## Description
The Python time sleep() function suspends the execution of the calling thread for a given number of seconds specified by the argument secs.
## Syntax
The syntax for the sleep() method is:
time.sleep(t)
## Parameters
* t -- The number of seconds to suspend execution.
## Return Value
This function does not return any value.
## Example
The following example demonstrates the usage of the sleep() function:
## Example
#!/usr/bin/python import time print"Start : %s" % time.ctime()time.sleep(5)print"End : %s" % time.ctime()
The output of the above example is:
Start : Tue Feb 17 10:19:18 2013End : Tue Feb 17 10:19:23 2013
YouTip