//Write a program to calculate perimeter of rectangle.
#include<iostream.h>
#include<conio.h>
{
clrscr();
int l,b,peri;
cout<<"Enter length -";
cin>>l;
cout<<"Enter breadth -";
cin>>b;
peri=2*(l+b);
cout<<"Perimeter of rectangle -"<<peri;
getch();
}
Output:
No comments:
Post a Comment