WAP C++ to find the area and perimeter of a rectangle .

#include <iostream>

using namespace std;

int main()
{
      int l,b,ar,p;
    cout<<"enter the length and breadth of a rectangle";
    cin>>l>>b;
    ar=l*b;
    p=2*(l+b);
    cout<<"Area of the rectangle="<<ar<<endl;
    cout<<"perimeter of rectangle="<<p;
    return 0;
}

Output:

enter the length and breadth of a rectangle2
3
Area of rectangle= 6
perimeter of rectangle=10