結果

問題 No.79 過小評価ダメ・ゼッタイ
ユーザー test
提出日時 2020-09-04 18:16:20
言語 C++14
(gcc 13.3.0 + boost 1.87.0)
結果
WA  
実行時間 -
コード長 373 bytes
コンパイル時間 1,682 ms
コンパイル使用メモリ 167,052 KB
実行使用メモリ 5,248 KB
最終ジャッジ日時 2024-11-26 09:25:49
合計ジャッジ時間 2,818 ms
ジャッジサーバーID
(参考情報)
judge2 / judge1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 11 WA * 11
権限があれば一括ダウンロードができます

ソースコード

diff #

#include <bits/stdc++.h>
#define rep(i, ss, ee) for (int i = ss; i < ee; ++i)
using namespace std;

int main() {
  int N, x;
  int ans_level = 0, ans_max = 0;
  cin >> N;
  vector<int> v(7);
  rep(i, 0, N) {
    cin >> x;
    v[x]++;
    if (ans_level < x && ans_max < v[x]) {
      ans_level = x;
      ans_max = v[x];
    }
  }
  cout << ans_level << endl;
  getchar();
}
0