from collections import deque import bisect N, K = map(int,input().split()) X = list(map(int,input().split())) A = list(map(int,input().split())) K -= 1 imosu = [0] * N called = [False] * N called[K] = True que = deque() que.append(K) while que: q = que.popleft() x = X[q] a = A[q] l = x - a r = x + a if l > r: l, r = r, l lidx = bisect.bisect_left(X, l) ridx = bisect.bisect_left(X, r+1) imosu[lidx] += 1 if ridx < N: imosu[ridx] -= 1 for i in range(lidx, ridx): if not called[i]: called[i] = True que.append(i) accums = [0] * (N+1) for i in range(N): accums[i+1] = accums[i] + imosu[i] ans = 0 for i in range(1, N+1): if accums[i] > 0: ans += 1 print(ans)