結果
| 問題 |
No.1443 Andd
|
| コンテスト | |
| ユーザー |
lam6er
|
| 提出日時 | 2025-04-15 23:19:43 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
TLE
|
| 実行時間 | - |
| コード長 | 460 bytes |
| コンパイル時間 | 253 ms |
| コンパイル使用メモリ | 81,708 KB |
| 実行使用メモリ | 211,168 KB |
| 最終ジャッジ日時 | 2025-04-15 23:21:14 |
| 合計ジャッジ時間 | 5,374 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge4 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| sample | AC * 3 |
| other | AC * 1 TLE * 1 -- * 18 |
ソースコード
N = int(input())
A = list(map(int, input().split()))
current = set()
current.add((0, 0))
for a in A:
new_current = set()
for (u, l) in current:
# Add operation
add_l = l + a
new_u_add = u + (add_l // 1024)
new_l_add = add_l % 1024
new_current.add((new_u_add, new_l_add))
# AND operation
new_l_and = l & a
new_current.add((0, new_l_and))
current = new_current
print(len(current))
lam6er