Wednesday 16 October 2013

CPP Program To Calculate Area of Rectangle

//Write a program to calculate area of rectangle.
#include<iostream.h>
#include<conio.h>
void main()
{
 clrscr();
 int l,b,area;
 cout<<"Enter length -";
 cin>>l;
 cout<<"Enter breadth -";
 cin>>b;
 area=l*b;
 cout<<"Area of rectangle -"<<area;
 getch();
}

Output:

No comments:

Comments System