Program to find circumference and area of a circle

Circumference of circle = 2*pi*r
Area of circle = pi*r*r

# include<stdio.h>
#include<conio.h>
void main()
{
int r;
float pi=3.14, area, circ;
clrscr();
printf("Enter radius of circle");
scanf("%d", &r);
area= pi*r*r;
circ= 2*pi*r;
printf("Area= %f",area);
printf("Circumference= %f",circ);
}

Post a Comment

0 Comments