# How to use the PI constant in C++?

C++Server Side ProgrammingProgramming

Here we will see how to use the PI constant in C++ program. The PI constant is present in the cmath header file. The name of the constant is M_PI. We can simply include that header file, and use the constant to perform operation.

In the following example we will see how to find area of a circle using PI constant.

## Example Code

#include <iostream>
#include <cmath>
using namespace std;
}
Area of a circle with radius 7 unit is: 153.938