Two Pointers
Find two values that add up to 20. The array is sorted, which is the key — it lets us start one pointer at each end and squeeze inward.
step 01/9
- comparing
- found it
- ruled out
Find two values that add up to 20. The array is sorted, which is the key — it lets us start one pointer at each end and squeeze inward.
step 01/9