玩个花的
2024-12-07 14:20:21
发布于:广东
1阅读
0回复
0点赞
#include <iostream>
#include <cstdio>
#include <algorithm>
#define double pair <pair <int, int>, string>
using namespace std;
double a[100005];
bool cmp(double n, double m){
if(n.first == m.first) return n.second < m.second;
return n.first > m.first;
}
int main(){
cin.tie(nullptr) -> sync_with_stdio(0);
cout.tie(nullptr) -> sync_with_stdio(0);
int n;
cin >> n;
for(int i = 1; i <= n; i++){
cin >> a[i].second >> a[i].first.first >> a[i].first.second;
}
sort(a + 1, a + n + 1, cmp);
for(int i = 1; i <= n; i++){
if(a[i].first.first >= 60 && a[i].first.second >= 60) cout << a[i].second << '\n';
}
return 0;
}
这里空空如也
有帮助,赞一个