Get Base 2 Logarithm of E in JavaScript



To get base 2 logarithms of E, use the Math LOG2E property. It returns base 2 logarithm of E which is approximately 1.442.

Example

You can try to run the following code to get base 2 logarithms of E in JavaScript:

<html>
   <head>
      <title>JavaScript Math LOG2E Property</title>
   </head>
   <body>
      <script>
         var property_value = Math.LOG2E
         document.write("Property Value is : " + property_value);
      </script>
   </body>
</html>
Updated on: 2020-01-16T07:29:51+05:30

278 Views

Kickstart Your Career

Get certified by completing the course

Get Started
Advertisements