Is there a faster alternative to python's Decimal?

前端 未结 5 760
野趣味
野趣味 2021-02-05 09:51

Does anyone know of a faster decimal implementation in python?

As the example below demonstrates, the standard library\'s decimal module is ~100 times slower than

5条回答
  •  悲哀的现实
    2021-02-05 10:23

    The GMP library is one of the best arbitrary precision math libraries around, and there is a Python binding available at GMPY. I would try that method.

提交回复
热议问题