On 25/10/2012 17:29, Chris Angelico wrote:
On Fri, Oct 26, 2012 at 3:17 AM, rusi <rustompm...@gmail.com> wrote:
On Oct 25, 8:57 pm, Steven D'Aprano <steve
+comp.lang.pyt...@pearwood.info> wrote:
py> min(t.repeat(number=10000, repeat=7))
0.6819710731506348
py> min(t.repeat(number=100, repeat=7))
4.141788959503174
That makes the "inelegant" solution using bin() and count() about 600
times faster than the mathematically clever solution using bitwise
operations.
You meant 600% I think?
It took six times longer to do one hundredth the iterations.
ChrisA
Oh no, not another PEP 393 foul up :)
--
Cheers.
Mark Lawrence.
--
http://mail.python.org/mailman/listinfo/python-list