LeetCode Merge Two Sorted Lists: The Dummy-Head Pattern
Solve LeetCode 21 Merge Two Sorted Lists with the dummy-head pointer pattern, plus a recursive variant, edge cases, and interview explanation tips.
·5 min read · #dsa#leetcode#linked-list
2 posts.
Solve LeetCode 21 Merge Two Sorted Lists with the dummy-head pointer pattern, plus a recursive variant, edge cases, and interview explanation tips.
Walk through LeetCode 206 Reverse Linked List with iterative pointer flipping and a clean recursive solution, plus complexity and interview talking points.