Log base 2 of large integers
Peter Pearson
ppearson at nowhere.invalid
Wed Aug 13 12:12:31 EDT 2014
On Wed, 13 Aug 2014 15:58:02 +0200, Peter Otten <__peter__ at web.de> wrote:
> Mok-Kong Shen wrote:
>
>> I like to compute log base 2 of a fairly large integer n but
>> with math.log(n,2) I got:
>>
>> OverflowError: long int too large to convert to float.
[snip]
> Or maybe our idea of "fairly large" differ; so how large is fairly large?
MK Shen used to hang out on the sci.crypt newsgroup, so we're
probably talking "cryptographically large" rather than "engineeringly
large".
--
To email me, substitute nowhere->spamcop, invalid->net.
More information about the Python-list
mailing list