title: Why does a simple arithmetic operation in Javascript shows results with a long precision?
body: <p>I'm working on something that requires some very simple arithmetic, but some of the results that come up are just mind-boggling.</p>
  
  <p>For example, paste the following in Chrome / Firefox / Opera DevTools console:</p>
  
  <pre><code>(211.8 - 0.5) + 0.8
  </code></pre>
  
  <p>The result should be <code>212.1</code>.... but I keep getting <code>212.10000000000002</code></p>
  
  <p>Although I can work around it using <code>toFixed()</code> or <code>Math.ceil()</code> etc. I would like to know what causes things like that to happen.</p>
  
  <p>I may have passed it off as a JSVM bug on a particular JS runtime, but it happens on multiple JS engines.</p>
  
  <p>Any JS / JSVM gurus care to enlighten me?</p>