Python Exercise Example 92
**Problem:** Time function example 2.
**Analysis:** None.
Example (Python 2.0+)
#!/usr/bin/python
-- coding: UTF-8 --
if
name
==
'
main
'
:
import
time
start
=
time
.
time
(
)
for
i
in
range
(
3000
)
:
i
end
=
time
.
time
(
)
end
start
The output of the above example is:
0
1
2
3
4
……
Python 100 Examples