結果
| 問題 |
No.871 かえるのうた
|
| コンテスト | |
| ユーザー |
👑 Kazun
|
| 提出日時 | 2020-09-05 19:28:22 |
| 言語 | PyPy3 (7.3.15) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 233 bytes |
| コンパイル時間 | 393 ms |
| コンパイル使用メモリ | 82,580 KB |
| 実行使用メモリ | 99,672 KB |
| 最終ジャッジ日時 | 2024-11-29 05:57:52 |
| 合計ジャッジ時間 | 5,208 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge5 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 19 WA * 30 |
ソースコード
N,K=map(int,input().split())
inf=float("inf")
X=list(map(int,input().split()))
X=[-inf]+X+[inf]
A=list(map(int,input().split()))
A=[0]+A+[0]
p=q=K
while X[p]-A[p]<=X[p-1]:
p-=1
while X[q+1]<=X[q]+A[q]:
q+=1
print(q-p+1)
Kazun