Sorting is a preprocessing step that makes hard problems easy.
What sorting enables:
Binary search: Find elements in instead of .
Two pointers: Find pairs with a target sum in instead of .
Greedy algorithms: Many greedy solutions start by sorting (activity selection, interval scheduling).
Duplicate detection: Adjacent elements after sorting reveal duplicates in .
Efficient merging: Merge sorted lists in or .
If you skip sorting, you'll write solutions where exists.