C Program to Find Area of Rectangle

Area of a rectangle can be calculated using length * breadth

#include<stdio.h>
 
int main()
{
    float length,breadth;
    float area;
    clrscr();
 
    printf(" Enter the Length of a Rectangle : ");
    scanf("%f",&length);
 
    printf("\n Enter the Breadth of a Rectangle : ");
    scanf("%f",&breadth);
 
    area = length * breadth;
 
    printf("\n Area of Rectangle is : %f",area);
    return 0;
}

 OUTPUT:

Enter the Length of Rectangle : 3.2

Enter the Breadth of Rectangle : 4

Area of Rectangle : 12.800000

Leave a Reply

Your email address will not be published.