Two PointersEvidence Contributing
Sort Then Two Pointers
Sort the input first, then fix one element and use two pointers over the remainder to find combinations meeting a target.
Practice Problems: 1
Difficulty: 0 Easy·1 Medium·0 Hard
Core technique
Review the technique, then try the mapped problems below. The right approach depends on each problem's constraints.
- Core Strategy: Sort the input first, then fix one element and use two pointers over the remainder to find combinations meeting a target.