提交时间:2025-12-26 15:23:47

运行 ID: 78126

#include <iostream> #include <string> using namespace std; int main() { int N; cin >> N; int max_score = -1; string top_student; for (int i = 0; i < N; ++i) { int score; string name; cin >> score >> name; if (score > max_score) { max_score = score; top_student = name; } } cout << top_student; return 0; }