#include<bits/stdc++.h>
using namespace std;priority_queue<int>q;int p,x,y,z;
int main(){ios::sync_with_stdio(0);cin.tie(0);
    for(cin>>p;cin>>p;)
        if(p<2)cin>>x>>y>>z,q.push(x*1040502+y*1030402+z*1030302);
        else if(p<3)x=q.top(),cout<<x/10201%101<<" "<<x/101%101<<" "<<x%101<<'\n';
        else q.pop();
}

无需使用结构体,可以压缩成一个整数来实现