<!DOCTYPE html>
<html>
<body>
<p>Click the button to return the absolute value of different numbers.</p>
<button onclick="myFunction()">Try it</button>
<p id="demo"></p>
<script>
function myFunction() {
var a = Math.abs(7.25);
var b = Math.abs(-7.25);
var c = Math.abs(null);
var d = Math.abs("Hello");
var e = Math.abs(2+3);
var x = a + "<br>" + b + "<br>" + c + "<br>" + d + "<br>" + e;
document.getElementById("demo").innerHTML = x;
}
</script>
</body>
</html>