#define _CRT_SECURE_NO_WARNINGS #include using namespace std; class Point { public: int x; int y; public: Point(int a = 0, int b = 0) { x = a, y = b; } Point operator+(Point p); }; Point Point::operator+(Point p) { // ? Point tmp; // ? tmp.x = x + p.x; // ? tmp.y = y + p.y; // ? return tmp; //? } int main() { Point p1(1, 2); Point p2(3, 6); p1 = p1 + p2; cout << p1.x << p1.y << endl; }