Hi!
I was just wondering...
Python 2.3.5 (#2, Mar 6 2006, 10:12:24)
[GCC 4.0.3 20060304 (prerelease) (Debian 4.0.2-10)] on linux2
Type "help", "copyright" , "credits" or "license" for more information.[color=blue][color=green][color=darkred]
>>> import timeit
>>> a = timeit.Timer('2 **100000000')
>>> b = timeit.Timer('1 122334455667788 99 * 112233445566778 899')
>>> a.timeit(1)[/color][/color][/color]
5.3986599445343 018[color=blue][color=green][color=darkred]
>>> b.timeit()[/color][/color][/color]
0.5930960178375 2441
Python 2.4.2 (#2, Nov 20 2005, 17:04:48)
[GCC 4.0.3 20051111 (prerelease) (Debian 4.0.2-4)] on linux2
Type "help", "copyright" , "credits" or "license" for more information.[color=blue][color=green][color=darkred]
>>> import timeit
>>> a = timeit.Timer('2 **100000000')
>>> b = timeit.Timer('1 122334455667788 99 * 112233445566778 899')
>>> a.timeit(1)[/color][/color][/color]
13.129707813262 939[color=blue][color=green][color=darkred]
>>> b.timeit()[/color][/color][/color]
0.7285480499267 5781
Why long numbers operations are slower in 2.4?
mk
--
. o . >> http://joker.linuxstuff.pl <<
. . o It's easier to get forgiveness for being wrong
o o o than forgiveness for being right.
I was just wondering...
Python 2.3.5 (#2, Mar 6 2006, 10:12:24)
[GCC 4.0.3 20060304 (prerelease) (Debian 4.0.2-10)] on linux2
Type "help", "copyright" , "credits" or "license" for more information.[color=blue][color=green][color=darkred]
>>> import timeit
>>> a = timeit.Timer('2 **100000000')
>>> b = timeit.Timer('1 122334455667788 99 * 112233445566778 899')
>>> a.timeit(1)[/color][/color][/color]
5.3986599445343 018[color=blue][color=green][color=darkred]
>>> b.timeit()[/color][/color][/color]
0.5930960178375 2441
Python 2.4.2 (#2, Nov 20 2005, 17:04:48)
[GCC 4.0.3 20051111 (prerelease) (Debian 4.0.2-4)] on linux2
Type "help", "copyright" , "credits" or "license" for more information.[color=blue][color=green][color=darkred]
>>> import timeit
>>> a = timeit.Timer('2 **100000000')
>>> b = timeit.Timer('1 122334455667788 99 * 112233445566778 899')
>>> a.timeit(1)[/color][/color][/color]
13.129707813262 939[color=blue][color=green][color=darkred]
>>> b.timeit()[/color][/color][/color]
0.7285480499267 5781
Why long numbers operations are slower in 2.4?
mk
--
. o . >> http://joker.linuxstuff.pl <<
. . o It's easier to get forgiveness for being wrong
o o o than forgiveness for being right.
Comment