結果
| 問題 |
No.79 過小評価ダメ・ゼッタイ
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2014-11-27 23:22:35 |
| 言語 | C++11(廃止可能性あり) (gcc 13.3.0) |
| 結果 |
AC
|
| 実行時間 | 18 ms / 5,000 ms |
| コード長 | 523 bytes |
| コンパイル時間 | 1,415 ms |
| コンパイル使用メモリ | 166,372 KB |
| 実行使用メモリ | 5,376 KB |
| 最終ジャッジ日時 | 2024-06-26 07:11:59 |
| 合計ジャッジ時間 | 2,421 ms |
|
ジャッジサーバーID (参考情報) |
judge5 / judge2 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 22 |
ソースコード
#include <bits/stdc++.h>
using namespace std;
typedef long long ll;
#define REP(i, n) for(int(i)=0;(i)<(n);++(i))
#define REPEAT(i, k, n) for(int(i)=(k);(i)<((k)+(n));++(i))
int main(){
int N,L;
cin >> N;
map<int,int> m;
REP(i,N){
cin >> L;
m[L]++;
}
int maxv = -1, maxi = -1;
for(auto &v : m){
if(maxv <= v.second){
maxv = v.second;
maxi = v.first;
}
}
cout << maxi << endl;
return 0;
}