Easy Tutorial
❮ Prop Frame Contentwindow Prop Img Name ❯

JavaScript valueOf() Method

JavaScript Number Object

Example

Returns the primitive value of a Number object:

n Output result:


Definition and Usage

The valueOf() method returns the primitive value of a number.


Browser Support

All major browsers support the valueOf() method.


Syntax

Return Value

Type Description
Number The primitive value of a number

Technical Details

| JavaScript Version: | 1.1 | | --- | --- |


JavaScript Number Object

❮ Prop Frame Contentwindow Prop Img Name ❯