#include<cstdio>
using namespace std;
struct node
{
int x,y;
node() {x=0,y=0;}// 赋初值
bool operator > (node &a) {return x.x>x;}//重构运算符
}a,b;
int main()
{
a=(node){3,3};b=(node){4,2};
if (a>b) b=a;
printf("%d %d
",b.x,b.y);
return 0;
}
希望能对你有用!