#include #include using namespace std; class Rectangle { public: Rectangle(); Rectangle(float length, float width); ~Rectangle(); float getArea(); float getPerimeter(); private: float mLength; float mWidth; }; Rectangle::Rectangle() : mLength(0), mWidth(0) { } Rectangle::Rectangle(float length, float width) : mLength(length), mWidth(width) { } Rectangle::~Rectangle() { } float Rectangle::getArea() { return mLength * mWidth; } float Rectangle::getPerimeter() { return 2 * (mLength + mWidth); } int main() { float m, n; cout << "Input the Length and Width: "; cin >> m >> n; Rectangle r1(m, n); cout << "The Area is: " << r1.getArea() << endl; cout << "The Perimeter: " << r1.getPerimeter() << endl; return 0; }