You are viewing a single comment's thread. Return to all comments →
for those who got problem (simple method using multimap)
int main() {
multimap<int,int> m; int n;cin>>n; for(int i=1;i<=n;i++) { int a,b; cin>>a>>b; m.insert(make_pair(a+b,i)); } for(multimap<int,int >::iterator me=m.begin();me!=m.end();me++ ) {cout<<me->second<<" "; } return 0;
}
Seems like cookies are disabled on this browser, please enable them to open this website
Jim and the Orders
You are viewing a single comment's thread. Return to all comments →
for those who got problem (simple method using multimap)
int main() {
}