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

2.C) Write a C program to calculate the area of a circle.

Answer:-

#include<stdio.h>
 
int main() {
   float radius, area;
 
   printf("\nEnter the radius of Circle : ");
   scanf("%d", &radius);
 
   area = 3.14 * radius * radius;
   printf("\nArea of Circle : %f", area);
 
   return (0);
}

Leave a Reply

Your email address will not be published. Required fields are marked *