結果

問題 No.706 多眼生物の調査
ユーザー hiragnhiragn
提出日時 2022-11-10 19:47:26
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 31 ms / 2,000 ms
コード長 262 bytes
コンパイル時間 222 ms
コンパイル使用メモリ 10,560 KB
実行使用メモリ 8,544 KB
最終ジャッジ日時 2023-10-01 03:40:01
合計ジャッジ時間 1,147 ms
ジャッジサーバーID
(参考情報)
judge12 / judge11
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 18 ms
8,544 KB
testcase_01 AC 19 ms
8,436 KB
testcase_02 AC 19 ms
8,400 KB
testcase_03 AC 20 ms
8,376 KB
testcase_04 AC 20 ms
8,408 KB
testcase_05 AC 23 ms
8,376 KB
testcase_06 AC 31 ms
8,488 KB
testcase_07 AC 19 ms
8,412 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

from collections import defaultdict


def main():
    n = int(input())
    d = defaultdict(int)
    for _ in range(n):
        s = len(input()) - 2
        d[s] += 1
    print(max(x for x in d if d[x] == max(d.values())))


if __name__ == "__main__":
    main()
0