Given a sorted (non-decreasing) array of integers arr and a target value k, find two elements at different positions whose sum equals k. Return their 0-based indices [i, j] with i < j. If several…
You've read your 3 free write-ups
Sign up free to keep reading. Your account opens the first 10 questions of every company.