JavaScript Global : Object
The following are properties of the global object. They can be accessed from anywhere without additional qualifiers.
Global Properties
Global Methods
Returns true if x is NaN. NaN is never equal to another Number, even if it is NaN, so you must use isNaN to check for NaN.
Example:
RunResults:
Converts str into an integral number. If base is not specified, parseInt will attempt to determine the base to use depending on the input. parseInt is more forgiving than Number(str) (or equivalently +str) in that it will ignore extra characters after the numeric portion of the string. If the first character is not a valid number in the specified base, parseInt will return NaN.
Example:
RunResults:
Copyright © JavaScripture.com