Question: in c++ please with explnation Complete the class below and define additional functions as the following: class Rectangle { public: Rectangle(int x, int y, int
Complete the class below and define additional functions as the following: class Rectangle \{ public: Rectangle(int x, int y, int Len, int Width); Rectangle operatort (Rectangle); bool operators (Rectangle); void operator* (float scale); void operatort+(); private: int x2,y3 int length, width; Ji A. void operator"(float scale) will scale the current rectangle up (if scale >1) or down (scale x-axis direction. C. bool operator > (Rectangle) will return true if the current rectangle's area is bigger than the received one. Hint: the area of a rectangle is calculated by multiplying the width by the length D. Rectangle operatort(Rectangle) will return a new rectangle, the new rectangle should be the smallest that can contain both rectangles (current and received). For example, B+C in the above figure will return a new rectangle that contains both B and C
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
