javascript(jquery)

[javascript/jquery] 소수점 계산

콩배 2021. 12. 1. 08:55

<script>
var a = 100;
var b = 0.05;

var sum = +(a+b).toFixed(2);
</script>