#define _USE_MATH_DEFINES #include #include #include #include #include #include #include #include #include #define ll long long #define dou(s) atof(s.c_str()) #define lon(s) atoll(s.c_str()) #define str(n) to_string(n) #define rep(i,a,b) for(ll i=a;i=a;i--) #define ALL(a) a.begin(),a.end() #define fion(n) fixed<=n&&a[lower_bound(ALL(a),n)-a.begin()]==n?lower_bound(ALL(a),n)-a.begin():-1) #define fist(s,t) ((int)s.find(t)) #define START int main(){cin.tie(0);ios::sync_with_stdio(false); #define END } using namespace std; struct pea{ll n,m,i;}; void msort(vector &a){ struct hikakukansu{ static bool unstable(const pea &x,const pea &y){return x.my.m);} }; sort(ALL(a),hikakukansu::stable); } START string s="ABC"; vector p(3); rep(i,0,3){ cin>>p[i].m>>p[i].n; p[i].i=i; } msort(p); rrep(i,2,0)cout<