#include <iostream>
using namespace std;
class Point
{
int _x, _y;
public:
Point(int x = 0, int y = 0) : _x(x), _y(y) {}
Point& operator++()
{
++_x;
++_y;
return *this;
}
Point operator++(int)
{
Point temp = *this;
_x++;
_y++;
return temp;
}
Point& operator--()
{
--_x;
--_y;
return *this;
}
Point operator--(int)
{
Point temp = *this;
_x--;
_y--;
return temp;
}
friend ostream& operator << (ostream& o, const Point& p);
};
/********** Begin **********/
/********** End **********/
ostream& operator << (ostream& o, const Point& p) {
o << '(' << p._x << ", " << p._y << ')';
return o;
}
int main()
{
int x, y;
cin >> x >> y;
Point p(x, y);
cout << p << endl;
cout << p++ << endl;
cout << ++p << endl;
cout << p-- << endl;
cout << --p << endl;
return 0;
}