結果

問題 No.2401 Dirty Shoes and Stairs
ユーザー titia
提出日時 2023-08-04 21:26:42
言語 Python3
(3.13.1 + numpy 2.2.1 + scipy 1.14.1)
結果
AC  
実行時間 127 ms / 2,000 ms
コード長 231 bytes
コンパイル時間 204 ms
コンパイル使用メモリ 12,416 KB
実行使用メモリ 16,140 KB
最終ジャッジ日時 2024-10-14 19:22:45
合計ジャッジ時間 2,480 ms
ジャッジサーバーID
(参考情報)
judge5 / judge4
このコードへのチャレンジ
(要ログイン)
ファイルパターン 結果
sample AC * 3
other AC * 30
権限があれば一括ダウンロードができます

ソースコード

diff #

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

LIST=[1]*(N+1)

now=0
for a in A:
    now+=a
    LIST[now]=0

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

for a in A:
    now-=a
    LIST[now]=0

print(sum(LIST))
0