| Run ID | 作者 | 问题 | 语言 | 测评结果 | Time | Memory | 代码长度 | 提交时间 |
|---|---|---|---|---|---|---|---|---|
| 153437 | 袁梓豪 | 19选班长 | C++ | Compile Error | 0 MS | 0 KB | 338 | 2026-05-17 11:45:36 |
#include <bits/stdc++.h> using namespace std; int main() { int n; cin >>n; int a[1000] = {0}; for (int i = 1; i <= 3 * n; i++) { int x; cin >> x; a[x] = a[x] + 1; } /* for (int i = 1; i <= n; i++) { cout << a[i] << " "; }*/ for(int i=2;i<=0;i++){ if(a[i]>a[m]){ m=i; } } return 0; cout<<m; }
Main.cc: In function 'int main()':
Main.cc:16:13: error: 'm' was not declared in this scope
if(a[i]>a[m]){
^
Main.cc:21:8: error: 'm' was not declared in this scope
cout<