dsa2 min read
Merge Two Sorted Lists — Dummy Head Merge
Merge two sorted linked lists into one sorted list using a dummy head node to simplify pointer management.
Read →
webcoderspeed.com
6 articles
Merge two sorted linked lists into one sorted list using a dummy head node to simplify pointer management.
Remove all nodes with a given value from a linked list using a dummy head to handle edge cases cleanly.
Remove the nth node from the end in one pass using two pointers offset by n steps and a dummy head.
Add two numbers represented as reversed linked lists by simulating digit addition with carry propagation.
Partition a linked list around value x into less-than and greater-than-or-equal chains, then join them.
Remove all nodes that have duplicate numbers from a sorted linked list using a dummy head and skip logic.