Return Styles: Pseud0ch, Terminal, Valhalla, NES, Geocities, Blue Moon. Entire thread

python is cool

Name: Anonymous 2006-12-06 17:34

(' DESU'*9000)[1:]

Name: Anonymous 2006-12-11 18:23

>>37
I don't think so, but let's do:

import sys
import timeit
print timeit.Timer('reduce(int.__add__, xrange(m))', 'm = int(sys.argv[1])').timeit(10000) / 10000.0


Result: adding 500 numbers that way takes 0.000139416266593 seconds (Athlon 64 3000+, Python 2.4.2 official build, Windows 2000)

Newer Posts
Don't change these.
Name: Email:
Entire Thread Thread List