summaryrefslogtreecommitdiffstats
path: root/Demo/classes
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>1994-02-17 12:36:58 (GMT)
committerGuido van Rossum <guido@python.org>1994-02-17 12:36:58 (GMT)
commite69d3fec87c4624e1d88d66efb7232ba5818a516 (patch)
treeab4ac32bb28e4a5163ba1b043ce0e1645943e01d /Demo/classes
parentd9193c67d66c63e329d01cea009bace2ae67480e (diff)
downloadcpython-e69d3fec87c4624e1d88d66efb7232ba5818a516.zip
cpython-e69d3fec87c4624e1d88d66efb7232ba5818a516.tar.gz
cpython-e69d3fec87c4624e1d88d66efb7232ba5818a516.tar.bz2
Use time.time() instead of time.millitimer()
Diffstat (limited to 'Demo/classes')
-rwxr-xr-xDemo/classes/Range.py10
1 files changed, 5 insertions, 5 deletions
diff --git a/Demo/classes/Range.py b/Demo/classes/Range.py
index c958f5a..18f626f 100755
--- a/Demo/classes/Range.py
+++ b/Demo/classes/Range.py
@@ -57,15 +57,15 @@ def test():
print range(10), range(-10, 10), range(0, 10, 2)
for i in range(100, -100, -10): print i,
print
- t1 = time.millitimer()
+ t1 = time.time()
for i in range(1000):
pass
- t2 = time.millitimer()
+ t2 = time.time()
for i in __builtin__.range(1000):
pass
- t3 = time.millitimer()
- print t2-t1, 'msec (class)'
- print t3-t2, 'msec (built-in)'
+ t3 = time.time()
+ print t2-t1, 'sec (class)'
+ print t3-t2, 'sec (built-in)'
test()