What I'm doing is getting user input with
var x = document.getElementById('id');
and the output is in whole numbers due to rounding errors, so 1.34 is 134 and I display it with
id.innerHTML = '$'.concat(amount / 100);
It is displaying "$1.32" correctly but I don't want "$1.3" for consistencies sake. So my question is what would be the best way for detecting that "$2.6" for example needs a "0" at the end whereas "$2.53 doesn't? And how to I implement that?