Write a C program to calculate the area and circumferences of a circle.

#include<stdio.h>
#include<conio.h>
void main()
   int r;
   int pi =3.1416;

float cir, area;
printf("/n enter the radious of the circle");
scanf("%d", & r);
cir = 2 * pi * r;
area = pi * r * r;
printf(" the circumference of the circle is = %d", cir);
printf(the area of the circle is = %d",area);
}

No comments:

Post a Comment