hello...
I was working on the decimal exercice.
And came up with this:
I was working on the decimal exercice.
And came up with this:
def dec(n):#trying to separate the integral part from the fraction part
return float(n)-int(n)
output:
>>> dec(3.8)
0.7999999999999998
Any ideas?