How do I turn a decimal from the decimal module into a string exactly so I can loop through in a list? Or is there another method that would work better when trying to work out the number of decimal places something is accurate to (ignoring trailing zeros at the end).
import decimal
number = decimal.Decimal('0.00000001')
print(str(number))
>>'1E-8'
instead I want:
print(str(number))
>> '0.00000001'
edit: I don't need .format to print it I need to loop through each digit in a for loop. Thanks