Area of a circle can simply be evaluated using following formula.
Area = pi * r^{2}
where r is radius of circle
C++
#include <iostream>
const double pi = 3.14159265358979323846;
using namespace std;
float findArea( float r)
{
return (pi * r * r);
}
int main()
{
float r, Area;
r = 5;
Area = findArea(r);
cout << "Area of Circle is :" << Area;
return 0;
}

C
#include <stdio.h>
#include <math.h>
#define PI 3.142
double findArea( int r)
{
return PI * pow (r, 2);
}
int main()
{
printf ( "Area is %f" , findArea(5));
return 0;
}

Java
class Test
{
static final double PI = Math.PI;
static double findArea( int r)
{
return PI * Math.pow(r, 2 );
}
public static void main(String[] args)
{
System.out.println( "Area is " + findArea( 5 ));
}
}

Python3
def findArea(r):
PI = 3.142
return PI * (r * r);
print ( "Area is %.6f" % findArea( 5 ));

C#
using System;
class GFG
{
static double PI = Math.PI;
static double findArea( int r)
{
return PI * Math.Pow(r, 2);
}
static void Main()
{
Console.Write( "Area is " + findArea(5));
}
}

PHP
<?php
function findArea( $r )
{
$PI =3.142;
return $PI * pow( $r , 2);
}
echo ( "Area is " );
echo (findArea(5));
return 0;
?>

Output:
Area is 78.550000
Attention reader! Don’t stop learning now. Get hold of all the important DSA concepts with the DSA Self Paced Course at a studentfriendly price and become industry ready.