7. Given the class definition
class A
{
public:
//constructors
// other members
private:
int x;
int y;
};
Give declarations of operator functions for each of the following ways to overload operator+ you must state where the declaration goes, whether within the class in the public or private section or outside the class. The operator + may be overloaded
a. as friend function
b. as member function
c. as non-friend, non-member function
[ 3 + 3 + 4 = 10 marks ]
Next week i have exam and this is one of the ques in sample paper ,please help me to solve it.