Math.PI Property in JavaScript

The PI property of the Math object represents the value of pi (Ratio of the circumference and diameter of a circle.)

Syntax

Its Syntax is as follows

Math.PI

Example

Live Demo

<html>
<title>JavaScript Example</title>
<body>
<script type="text/javascript">
var result = Math.PI;
document.write(result);
</script>
</body>
</html>

Output

3.141592653589793
karthikeya Boyini

I love programming (: That's all I know