結果

問題 No.2401 Dirty Shoes and Stairs
コンテスト
ユーザー なえしら
提出日時 2024-08-16 22:27:19
言語 PyPy3
(7.3.23 + ACL)
コンパイル:
pypy3 -mpy_compile _filename_
実行:
pypy3 _filename_
結果
WA  
実行時間 -
コード長 258 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 280 ms
コンパイル使用メモリ 95,964 KB
実行使用メモリ 154,624 KB
最終ジャッジ日時 2026-08-25 02:00:41
合計ジャッジ時間 5,435 ms
ジャッジサーバーID
(参考情報)
judge1_0 / judge3_0
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 8 WA * 22
権限があれば一括ダウンロードができます

ソースコード

diff #
raw source code

from itertools import accumulate

N = int(input())
M = int(input())
A = list(map(int, input().split()))
L = int(input())
B = list(map(int, input().split()))

S = set(accumulate(A, initial=0))
T = set(accumulate(B, initial=0))
U = S | T

print(N + 1 - len(U))
0