結果

問題 No.79 過小評価ダメ・ゼッタイ
ユーザー 👑 yumechiyumechi
提出日時 2015-06-12 03:52:11
言語 Python3
(3.11.6 + numpy 1.26.0 + scipy 1.11.3)
結果
WA  
(最新)
AC  
(最初)
実行時間 -
コード長 276 bytes
コンパイル時間 328 ms
コンパイル使用メモリ 10,716 KB
実行使用メモリ 10,212 KB
最終ジャッジ日時 2023-08-02 02:59:03
合計ジャッジ時間 2,263 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,860 KB
testcase_01 WA -
testcase_02 AC 15 ms
7,776 KB
testcase_03 AC 15 ms
7,852 KB
testcase_04 AC 14 ms
7,912 KB
testcase_05 AC 53 ms
10,024 KB
testcase_06 AC 15 ms
7,852 KB
testcase_07 AC 16 ms
7,796 KB
testcase_08 AC 16 ms
7,788 KB
testcase_09 AC 16 ms
7,796 KB
testcase_10 AC 14 ms
7,788 KB
testcase_11 AC 15 ms
7,872 KB
testcase_12 AC 15 ms
7,868 KB
testcase_13 AC 14 ms
7,924 KB
testcase_14 AC 38 ms
9,096 KB
testcase_15 AC 24 ms
8,708 KB
testcase_16 AC 44 ms
9,472 KB
testcase_17 WA -
testcase_18 AC 43 ms
9,416 KB
testcase_19 AC 35 ms
9,120 KB
testcase_20 AC 53 ms
10,068 KB
testcase_21 AC 16 ms
7,796 KB
testcase_22 WA -
testcase_23 AC 49 ms
9,708 KB
testcase_24 WA -
権限があれば一括ダウンロードができます

ソースコード

diff #

N = int(input())
arr = list(map(int, input().split()))
dic = {}
for a in arr:
    if a not in dic:
        dic.update({a:1})
    else:
        dic[a] += 1
maxkey = -1
maxval = -111
for k, v in dic.items():
	if v >= maxval:
		maxval = v
		maxkey = max(maxkey, k)
print(maxkey)
0