Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- struct cmp {
- bool operator() (const pair <int, string> &a, const pair <int, string> &b) const {
- if (a.first > b.first) {
- return true;
- }
- else if (a.first < b.first) {
- return false;
- }
- else if (a.second < b.second) {
- return true;
- }
- return false;
- }
- };
- set <pair <int, string>, cmp> s;
Advertisement
Add Comment
Please, Sign In to add comment