How do I start this?

I missed couple days of class (sick)... So yes this is a HW problem but i dont need the answer just point me to the right direction.

define a class rectangleType that stores length and width of a rectangle.

a.) Overload +,-,<,>,<=,>=,==,!=operators for your class. For example the following should be possible in your main program:

rectangleType rectangle4by8(4,8);
rectangleType rectangle3By2(3,2);
rectangleType rectangle7By10(7,10)=rectangle4By8+rectangle3By2;

b.) write the definitions of the functions to overload the increment, decrement, add, and multiply operators as nonmembers (friends)

c.) add friend function that overloads << operator, to make the following code possible in main:

cout<<rectangle4By8<<endl;

d.) demonstrate how all of your functions work inside main.
how i do last part for a. I got the first two
Topic archived. No new replies allowed.