Number.prototype.toFixed()
Number.prototype.toFixed() is a JavaScript method in the Number category. Formats a number using fixed-point notation. The syntax is num.toFixed(digits). It returns A string representing the number. A typical example: (1.234).toFixed(2) // "1.23". Another practical use — Format currency: const amount = 123.456 console.log('