(Jul-16-2023, 11:25 PM)Skaperen Wrote: so there is nothing to do this already defined in some module
But there is, I thought you knew. It is
decimal for computations with arbitrary precision.
import decimal
number = "23278327809283209832832093822093820938029830398320938209.23232332323232323"
decimal.getcontext().prec = len(number) # Set the precision. (Perhaps decimal point should not be counted.)
print(number)
print(decimal.Decimal(number) * decimal.Decimal(2))
Output:
23278327809283209832832093822093820938029830398320938209.23232332323232323
46556655618566419665664187644187641876059660796641876418.46464664646464646