#include<iostream.h>
class string
{
private:
int x,y;
public:
string(){}
string(int a,int b)
{
x=a;y=b;
}
void display()
{
cout<<"("<<x<<","<<y<<")"<<endl;
}
void operator +=(string m2)
{
x+=m2.x;
y+=m2.y;
}
};
void main()
{
string m1(1,2),m2(3,4);
cout<<"m1:";
m1.display();
cout<<"m2:";
m2.display();
m1+=m2;
cout<<"执行m1+=m2后,m1:";m1.display();
}