how to get the thighest bit position in big integers?

bearophileHUGS at lycos.com bearophileHUGS at lycos.com
Mon Oct 6 12:23:52 CEST 2008


Mark Dickinson:
> See alsohttp://bugs.python.org/issue3439
> where there's a proposal to expose the _PyLong_NumBits method.  This
> would give an O(1) solution.

Sounds useful, I've used the gmpy.numdigits(x [,base]) few times.

Bye,
bearophile



More information about the Python-list mailing list