In article <mailman.324.1235098726.11746.python-l...@python.org>, Maxim Khitrov <mkhit...@gmail.com> wrote: > >Interesting, though I'm not able to replicate that last outcome. The >string method is still the fastest on my machine. Furthermore, it >looks like the order in which you do the multiplication also matters - >(8 * size * '\0') is faster than ('\0' * 8 * size).
That's not surprising -- the latter does two string multiplication operations, which I would expect to be slower than int multiplication. -- Aahz (a...@pythoncraft.com) <*> http://www.pythoncraft.com/ "All problems in computer science can be solved by another level of indirection." --Butler Lampson -- http://mail.python.org/mailman/listinfo/python-list