結果
問題 | No.709 優勝可能性 |
ユーザー |
👑 ![]() |
提出日時 | 2021-02-12 01:13:22 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 167 ms / 3,500 ms |
コード長 | 703 bytes |
コンパイル時間 | 122 ms |
コンパイル使用メモリ | 82,224 KB |
実行使用メモリ | 104,184 KB |
最終ジャッジ日時 | 2024-07-18 11:51:02 |
合計ジャッジ時間 | 3,571 ms |
ジャッジサーバーID (参考情報) |
judge3 / judge4 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 2 |
other | AC * 22 |
ソースコード
import sysinput=sys.stdin.readlinewrite=sys.stdout.writeN,M=map(int,input().split())Count =[0]*(M+1)Chance=[0]*NMax =[-1]*MPerson=[[] for _ in range(M)]X=[0]*Nfor k in range(N):R=list(map(int,input().split()))Count[0]+=1for j in range(M):if R[j]>=Max[j]:Count[Chance[k]]-=1Chance[k]+=1Count[Chance[k]]+=1if R[j]==Max[j]:Person[j].append(k)elif R[j]>Max[j]:for t in Person[j]:Count[Chance[t]]-=1Chance[t]-=1Count[Chance[t]]+=1Max[j]=R[j]Person[j]=[k]X[k]=k+1-Count[0]write("\n".join(map(str,X)))