Question DSA-TP-0001
EasyWhat is the two-pointer technique?
- A.
Running two loops nested
- B.
Using two indices that move through a data structure, often from both ends or at different speeds
- C.
Show answer and explanation
Answer: B
It often turns an O(n²) pair search into O(n), for example on a sorted array.