Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
---|---|---|---|---|---|---|---|---|
126867 | 左维哲 | 19选班长 | C++ | Accepted | 10 MS | 268 KB | 331 | 2025-07-22 13:27:41 |
#include<bits/stdc++.h> using namespace std; int main() { int n, min = 1; cin >> n; int b[n+1]; // for(int i=1;i<=n;i++){ b[i]=0; } for (int i = 0; i < 3*n; i++) { int x; cin >> x; b[x]++; } for (int i = 1; i <=n; i++) { if (b[min] < b[i]) { min = i; } } cout << min; return 0; }