結果
| 問題 |
No.3311 フィルター
|
| コンテスト | |
| ユーザー |
detteiuu
|
| 提出日時 | 2025-10-30 23:27:47 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
AC
|
| 実行時間 | 106 ms / 2,000 ms |
| コード長 | 232 bytes |
| コンパイル時間 | 378 ms |
| コンパイル使用メモリ | 82,660 KB |
| 実行使用メモリ | 77,196 KB |
| 最終ジャッジ日時 | 2025-10-30 23:27:50 |
| 合計ジャッジ時間 | 2,953 ms |
|
ジャッジサーバーID (参考情報) |
judge4 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 21 |
ソースコード
N, M = map(int, input().split())
S = [int(input(), 2) for _ in range(M)]
bit = (1<<N)-1
for s in S:
bit &= s
if bit != 0 and bit in S and M == 1<<sum((bit>>i & 1) == 0 for i in range(N)):
print("Yes")
else:
print("No")
detteiuu