title: How numbers are summed in python?
body: <p>I am adding two numbers in python.</p>
  
  <pre><code>A = 29.000988000000003
  B = 10
  </code></pre>
  
  <p>in python <code>A+B</code> gives <code>39.00098800000001.</code></p>
  
  <p>Can someone explain me what exactly is going on? According to me the last digit should be 3 not 1. Even with <code>B = 10.0</code> also gives same results.. </p>
  
  <p>Basically I want to know what is the machine accuracy of python and how I can avoid such incidents?</p>