N, K = map(int, input().split()) X = list(map(int, input().split())) A = list(map(int, input().split())) K -= 1 Q = [K] lp = K rp = K li = K ri = K rlimit = K ans = 0 while Q: x = Q.pop() lp = min(lp, X[x] - A[x]) while 0 < li and lp <= X[li - 1]: li -= 1 Q.append(li) rp = max(rp, X[x] + A[x]) while ri < N - 1 and X[ri + 1] <= rp: ri += 1 Q.append(ri) print(ri - li + 1)