How do I get the numbers after a decimal point?
For example, if I have
5.55, how do i get
An easy approach for you:
number_dec = str(number-int(number))[1:]
5.55 % 1
Keep in mind this won't help you with floating point rounding problems. I.e., you may get:
Or otherwise a little off the 0.55 you are expecting.