Possible Duplicate:
Is JavaScript's Math broken?
<html>
<body>
<script type="text/javascript">
var w = 0;
var weight1 = parseFloat("0.6");
var weight2 = parseFloat("0.3");
w = weight1 + weight2;
document.write("total weight: " + w);
</script>
</body>
</html>
Why does this print 0.8999999999999999 and not 0.90000000