title: Python:computing the number of digits after decimal gives wrong answer
body: <p>I have a floating point field in one of my form, consider it as <em>field_x</em>. Based on that <em>field_x</em> i have some computation.
  <strong>After all if <em>field_x</em> have n digits after decimal result also should have n digits.</strong></p>
  
  <p>For example:
  field_x = 0.00000001(n digits after decimal)</p>
  
  <p>result = some calculations</p>
  
  <p>if result = 22
  i have to display it as 22.00000000(n digits after decimal)</p>
  
  <p><code>len(str(number-int(number))[1:])</code> Gives the answer</p>
  
  <p>**here the number can be 0.00101,0.110,0.787,etc</p>
  
  <p>But for some values like <em>0.000001</em> its giving incorrect answer</p>