Javascript examples for Number Operation:Number Format
Format number with decimal point as a separator
<html> <head> <meta name="viewport" content="width=device-width"> </head> <body> <script> var num=(999999999999999).toString().split("").reverse(); [3,6,7,10,13].forEach((i,o)=>num.splice(o+i,0,".")); num=num.reverse().join(""); console.log(num); </script> </body>/* w ww . j ava2s . c o m*/ </html>