Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- typedef struct Comp{
- bool operator()(const pair<int,int>&a, const pair<int,int>&b){
- if(a.f != b.f){
- return a.f<b.f;
- }
- return a.s>b.s;
- }
- };
- pair<int,int>p[MAX];
- Comp c;
- sort(p,p+(MAX-1),c);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement