結果
| 問題 |
No.871 かえるのうた
|
| コンテスト | |
| ユーザー |
|
| 提出日時 | 2019-09-03 13:09:13 |
| 言語 | Python3 (3.13.1 + numpy 2.2.1 + scipy 1.14.1) |
| 結果 |
WA
|
| 実行時間 | - |
| コード長 | 324 bytes |
| コンパイル時間 | 253 ms |
| コンパイル使用メモリ | 12,800 KB |
| 実行使用メモリ | 74,012 KB |
| 最終ジャッジ日時 | 2024-12-23 20:53:53 |
| 合計ジャッジ時間 | 67,988 ms |
|
ジャッジサーバーID (参考情報) |
judge2 / judge1 |
(要ログイン)
| ファイルパターン | 結果 |
|---|---|
| other | AC * 18 WA * 11 TLE * 20 |
ソースコード
N, K = map(int, input().split())
X = list(map(int, input().split()))
A = list(map(int, input().split()))
hear = [K-1]
cried = []
while len(hear):
h = hear.pop()
cried.append(h)
for i, c in enumerate(X):
if X[h] - A[h] <= c <= X[h] + A[h] and i not in cried:
hear.append(i)
print(len(cried))