Erik Max Francis: > If len(bytes) is large, you might want to use `xrange`, too. `range` > creates a list which is not really what you need.
That's right for Python, but Psyco uses normal loops in both cases, you can time this code in the two situations: def foo1(n): count = 0 for i in range(n): count += 1 print count def foo2(n): count = 0 for i in xrange(n): count += 1 print count import psyco; psyco.full() N = 100000000 #foo1(N) foo2(N) Bye, bearophile -- http://mail.python.org/mailman/listinfo/python-list