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