JavaScript | Math Object Complete Reference

The Math object is used to perform mathematical operations on numbers.

Example:

filter_none

edit
close

play_arrow

link
brightness_4
code

<!DOCTYPE html>
<html>
    <body>
        <h2>GeeksforGeeks</h2>
  
        <script>
// Return PI value(3.141592653589793)
            document.write(Math.PI);
        </script>
    </body>
</html>

chevron_right


Output:

There are many Math object properties and Methods in JavaScript which are listed below:



Math object properties:

Math object Methods:

   

full-stack-img




My Personal Notes arrow_drop_up

Check out this Author's contributed articles.

If you like GeeksforGeeks and would like to contribute, you can also write an article using contribute.geeksforgeeks.org or mail your article to contribute@geeksforgeeks.org. See your article appearing on the GeeksforGeeks main page and help other Geeks.

Please Improve this article if you find anything incorrect by clicking on the "Improve Article" button below.