結果
問題 | No.607 開通777年記念 |
ユーザー |
👑 |
提出日時 | 2022-01-19 21:19:33 |
言語 | PyPy3 (7.3.15) |
結果 |
AC
|
実行時間 | 228 ms / 2,000 ms |
コード長 | 303 bytes |
コンパイル時間 | 211 ms |
コンパイル使用メモリ | 82,176 KB |
実行使用メモリ | 77,568 KB |
最終ジャッジ日時 | 2024-11-23 14:04:53 |
合計ジャッジ時間 | 2,098 ms |
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
ファイルパターン | 結果 |
---|---|
sample | AC * 3 |
other | AC * 10 |
ソースコード
n, m = map(int, input().split())X = [0] * nfor _ in range(m):A = list(map(int, input().split()))X = [a + x for a, x in zip(A, X)]se = {0}tot = 0for x in X:tot += xif tot - 777 in se:print("YES")exit()se.add(tot)print("NO")