THE WORLD'S LARGEST WEB DEVELOPER SITE
HTMLCSSJAVASCRIPTSQLPHPBOOTSTRAPJQUERYANGULARXML
 

JavaScript LOG2E Property

Math Object Reference JavaScript Math Object

Example

Return the base-2 logarithm of E:

Math.LOG2E;

The result will be:

1.4426950408889634
Try it yourself »

Definition and Usage

The LOG2E property returns the base-2 logarithm of E, approximately 1.442.


Browser Support

Property
LOG2E Yes Yes Yes Yes Yes

Syntax

Math.LOG2E

Technical Details

Return Value: A Number, representing the base-2 logarithm of E
JavaScript Version: 1.0

Math Object Reference JavaScript Math Object