Suppose that the operator << is to be overloaded for a user-defined class mystery
Question # 00058880
Posted By:
Updated on: 04/03/2015 04:26 AM Due on: 04/03/2015
1. Suppose that the operator << is to be overloaded for a user-defined class mystery. Why must << be overloaded as a friend function?
2. Suppose that the binary operator + is overloaded as a member function for a class strange. How many parameters does the function operator+ have?
3. When should a class overload the assignment operator and define the copy constructor?
-
Rating:
5/
Solution: Suppose that the operator << is to be overloaded for a user-defined class mystery