Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
97324 Kevin 19选班长 C++ Wrong Answer 0 MS 268 KB 275 2024-11-13 15:09:58

Tests(7/10):


Code:

#include<bits/stdc++.h> using namespace std; int b[100]; int main(){ int n,t; cin>>n; for(int i=1;i<=n*3;i++){ cin>>t; b[t]++; } int max=b[1]; int xh=1; for(int i=2;i<=5;i++){ if(max<b[i]){ max=b[i]; xh=i; } } cout<<xh; return 0; }


Run Info:

------Input------
10 8 4 1 3 10 5 2 1 8 8 9 7 8 10 8 1 5 1 9 9 3 6 4 10 10 10 2 2 5 5
------Answer-----
8
------Your output-----
1