結果

問題 No.2401 Dirty Shoes and Stairs
コンテスト
ユーザー なえしら
提出日時 2024-08-16 22:27:19
言語 PyPy3
(7.3.17)
コンパイル:
pypy3 -mpy_compile _filename_
実行:
pypy3 _filename_
結果
WA  
実行時間 -
コード長 258 bytes
記録
記録タグの例:
初AC ショートコード 純ショートコード 純主流ショートコード 最速実行時間
コンパイル時間 208 ms
コンパイル使用メモリ 84,992 KB
実行使用メモリ 146,816 KB
最終ジャッジ日時 2026-04-03 21:25:06
合計ジャッジ時間 4,322 ms
ジャッジサーバーID
(参考情報)
judge3_1 / judge5_1
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
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