Camion <[email protected]> added the comment:
math.log10 works perfectly on integers which are too large to be converted to
floats. I see no reason why it couldn't work as well with fractions.
>>> math.log10(math.factorial(10000))
35659.45427452078
>>> math.log10(math.factorial(1000000))
5565708.917186718
>>> math.log10(float(math.factorial(10000)))
Traceback (most recent call last):
File "<pyshell#36>", line 1, in <module>
math.log10(float(math.factorial(10000)))
OverflowError: int too large to convert to float
----------
_______________________________________
Python tracker <[email protected]>
<https://bugs.python.org/issue42886>
_______________________________________
_______________________________________________
Python-bugs-list mailing list
Unsubscribe:
https://mail.python.org/mailman/options/python-bugs-list/archive%40mail-archive.com