<html>
<body>
<h1>JavaScript Math</h1>
<h2>The Math.log2() Method</h2>
<p>The Mat.log2() method returns the base 2 logarithm of a number:</p>
<p id="demo"></p>
<script>
let a = Math.log2(-Infinity);
let b = Math.log2(Infinity);
let c = Math.log2(-0);
let d = Math.log2(0);
let e = Math.log2(-1);
let f = Math.log2(1);
let g = Math.log2(2);
document.getElementById("demo").innerHTML =
a + "<br>" + b + "<br>" + c + "<br>" + d + "<br>" + e + "<br>" + f + "<br>" + g;
</script>
</body>
</html>