結果

問題 No.706 多眼生物の調査
ユーザー はむ吉🐹はむ吉🐹
提出日時 2018-06-30 13:43:21
言語 Python3
(3.12.2 + numpy 1.26.4 + scipy 1.12.0)
結果
AC  
実行時間 36 ms / 2,000 ms
コード長 350 bytes
コンパイル時間 688 ms
コンパイル使用メモリ 10,592 KB
実行使用メモリ 9,228 KB
最終ジャッジ日時 2023-09-13 16:17:01
合計ジャッジ時間 883 ms
ジャッジサーバーID
(参考情報)
judge11 / judge15
このコードへのチャレンジ
(要ログイン)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 18 ms
8,540 KB
testcase_01 AC 17 ms
8,592 KB
testcase_02 AC 19 ms
8,612 KB
testcase_03 AC 19 ms
8,544 KB
testcase_04 AC 20 ms
8,696 KB
testcase_05 AC 28 ms
8,684 KB
testcase_06 AC 36 ms
9,228 KB
testcase_07 AC 18 ms
8,548 KB
権限があれば一括ダウンロードができます

ソースコード

diff #

#!/usr/bin/env python3

import collections


def most_common_number(ss):
    ctr = collections.Counter(s.count("^") for s in ss)
    return max(k for k, v in ctr.items() if v == ctr.most_common(1)[0][1])


def main():
    n = int(input())
    ss = [input() for _ in range(n)]
    print(most_common_number(ss))


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