Run ID 作者 问题 语言 测评结果 Time Memory 代码长度 提交时间
64880 谌俊林 19选班长 C++ Wrong Answer 1 MS 268 KB 307 2024-01-22 15:32:27

Tests(0/10):


Code:

#include<iostream> #include<cstdio> using namespace std; int main(){ int n,t,max_d=0,max_b=0; cin>>n; int a[n+1]; for(int i=1;i<=n;i++) a[i]=0; for(int i=1;i<=n*3;i++){ cin>>a[i]; t++; if(a[i]>max_d){ max_d=a[i]; max_b=i; } } cout<<max_b; return 0; }


Run Info:

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