結果

問題 No.709 優勝可能性
ユーザー roarisroaris
提出日時 2019-08-07 21:15:49
言語 Python3
(3.11.6 + numpy 1.26.0 + scipy 1.11.3)
結果
TLE  
実行時間 -
コード長 466 bytes
コンパイル時間 721 ms
コンパイル使用メモリ 10,732 KB
実行使用メモリ 12,904 KB
最終ジャッジ日時 2023-09-25 23:15:44
合計ジャッジ時間 7,196 ms
ジャッジサーバーID
(参考情報)
judge13 / judge15
このコードへのチャレンジ(β)

テストケース

テストケース表示
入力 結果 実行時間
実行使用メモリ
testcase_00 AC 16 ms
7,816 KB
testcase_01 AC 16 ms
7,880 KB
testcase_02 AC 15 ms
7,888 KB
testcase_03 AC 16 ms
7,840 KB
testcase_04 AC 15 ms
7,768 KB
testcase_05 AC 15 ms
7,844 KB
testcase_06 AC 16 ms
7,816 KB
testcase_07 AC 16 ms
7,836 KB
testcase_08 AC 16 ms
7,768 KB
testcase_09 AC 16 ms
7,836 KB
testcase_10 TLE -
testcase_11 -- -
testcase_12 -- -
testcase_13 -- -
testcase_14 -- -
testcase_15 -- -
testcase_16 -- -
testcase_17 -- -
testcase_18 -- -
testcase_19 -- -
testcase_20 -- -
testcase_21 -- -
testcase_22 -- -
testcase_23 -- -
権限があれば一括ダウンロードができます

ソースコード

diff #

N, M = map(int, input().split())
max_para = [0] * M
set_list = [set()] * M

for i in range(N):
    para = list(map(int, input().split()))
    
    for j in range(M):
        if para[j] == max_para[j]:
            set_list[j].add(i)
        elif para[j] > max_para[j]:
            max_para[j] = para[j]
            set_list[j] = {i}
    
    ans_set = set()
    
    for set_list_i in set_list:
        ans_set |= set_list_i
    
    ans = len(ans_set)
    print(ans)
0