C Program to Find Area of Rectangle


Prev Tutorial Next Tutorial

Find Area of Rectangle Program in C

For calculate area and parameter of rectangle you need length and breath of rectangle and apply below formula;

Formula

Area of Rectangle = length*breath;
Parameter of Rectangle = 2*(length+breath);

program to find area of rectangle

#include<stdio.h>
#include<conio.h>

void main()
{
int length,breath,area_rec=0,parameter=0;
clrscr();
printf("Enter Length and Breath of Rectangle: ");
scanf("%d%d",&length,&breath);
area_rec=length*breath;
parameter=2*(length+breath);
printf("\nArea of Ractangle: %d",area_rec);
printf("\nParameters of Rectangle: %d",parameter);
getch();
}

Output

Enter Length and Breath of Rectangle: 5 4
Area of Rectangle: 20
Parameters of Ractangle: 18

Prev Tutorial Next Tutorial



Download Projects

Advertisements

FREE Online Google Play APK Downloader

Buy APP Installs, Buy 100% Genuine Installs