MathObject-2

 

javaScript Math.PI will return the PI value. See the code snippet:

 
 
 
<!DOCTYPE html> <html> <head> <title>Welcome to LearnKode - A code learning platform</title> </head> <body> <p id="sample"></p> <script> var result = Math.PI; document.getElementById("sample").innerHTML = result; </script> </body> </html>
Output