While looking for an answer of my problem "How to round numbers with decimals in javascript", I found this SO answer https://stackoverflow.com/a/14194399/177665
This can be done using Javascript as follows:
this.value = Math.round((amt*100)/100).toFixed(2));
I try it and notice there is an extra )
at the end producing the following error: SyntaxError: Unexpected token )
. So I edit the answer like this:
This can be done using Javascript as follows:
this.value = Math.round((amt*100)/100).toFixed(2);
But I can't save because
Edits must be at least 6 characters; is there something else to improve in this post?
What I am supposed to do? I do not want to modify the answer. Can't we have a checkbox 'code fix' that bypasses this limitation?
(Math.round(amt*100)/100).toFixed(2);
?