JavaScript Number Object Methods

In JavaScript, the Number object is used to work with the numbers. It has various properties and methods which help you to work with various numerical operations.

JavaScript Number Object Methods: This section contains various Number object properties and methods with examples.

List of JavaScript Number Object Properties & Methods

Property/Method Description
MAX_VALUE It returns the maximum value of a number that is possible in JavaScript.
MIN_VALUE It returns the minimum value of a number that is possible in JavaScript.
isNaN() It checks whether a number is a valid number or not. It returns true if the number is "Not-a-Value"
isFinite() It checks whether a given number is a finite number or not.
isInteger() It checks whether a given number is an integer or not.
toString() It converts a number to the string. It can also be used to convert a given number to the string with specified number systems like binary string, octal string, and hexadecimal string.
toExponential() It converts a number into exponential notation format.
toFixed() It converts a number to the string with a given fixed number of decimals.
toPrecision() It converts a number to a specified length, including the decimal point (if target length is short).


Comments and Discussions!

Load comments ↻





Copyright © 2024 www.includehelp.com. All rights reserved.