FWIW<p>scala&gt; BigDecimal(&quot;0.1&quot;) + BigDecimal(&quot;0.2&quot;)<p>res0: scala.math.BigDecimal = 0.3<p>Or as I wrote in 2008 <a href="http:&#x2F;&#x2F;codemonkeyism.com&#x2F;once-and-for-all-do-not-use-double-for-money&#x2F;" rel="nofollow">http:&#x2F;&#x2F;codemonkeyism.com&#x2F;once-and-for-all-do-not-use-double-...</a>