Given a Decimal
number in python how can I find the number of digits past the decimal point?
assert digits(Decimal('1.2345')) == 4
assert digits(Decimal('1000')) == 0
assert digits(Decimal('1.00')) == 2
assert digits(Decimal('1E+5')) == 0
assert digits(Decimal('1.2E+5')) == 0