C Program to Calculate Area of Circle


C Program for Beginners : Area of Circle


Shape : Circle
   Formula : Π * r * r
 Definition :

  1. Ellipse in which the two axes are of equal length
  2. Plane curve generated by one point moving at a constant distance from a fixed point
  3. You can compute the area of a Circle if you know its radius.

Program :

#include<stdio.h>
#include<conio.h>
void main()
{
float radius,area;
clrscr();  // Clear Screen

printf("nEnter the radius of Circle : ");
scanf("%d",&radius);

area = 3.14 * radius * radius;

printf("nArea of Circle : %f",area);
getch();
}

Output :

Enter the radius of Circle : 2.0
Area of Circle : 6.14