Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
128880 邹子涵 19众数 C++ Compile Error 0 MS 0 KB 249 2025-08-20 15:24:14

Tests(0/0):


Code:

#include<bits/stdc++.h> using namespace std; int main() { int n; cin>>n; int b[1001]; for(int i=1;i<=1000;i++){ b[i]=0; } for(int i=0;i<n;i++){ int m; cin>>m; b[m]++; } int e=1; for(int i=1;i<=1000;i++){ if(b[i]>b[e]){ e=i; } } cout<<e; return 0}


Run Info:

Main.cc:1:25: warning: extra tokens at end of #include directive
 #include using namespace std; int main() 
                         ^
Main.cc:2:1: error: expected unqualified-id before '{' token
 {
 ^