Search
 
SCRIPT & CODE EXAMPLE
 
CODE EXAMPLE FOR JAVASCRIPT

rounding number to x decimals javascript

let num = 12.5452411;
num = num.toFixed(3); // 12.545
Source by stackoverflow.com #
 
PREVIOUS NEXT
Tagged: #rounding #number #decimals #javascript
ADD COMMENT
Topic
Name
3+8 =