Skip to content

Linked List

A linked list is a chain of nodes where each node points to the next one — like a scavenger hunt where every clue tells you where the next one is. There is no index access, so the skill is rewiring pointers without losing the rest of the chain.

After this topic: You can reverse, merge and split lists, use fast/slow pointers, and use a dummy node to remove edge cases.

Do these first: Two Pointers

0 of 11 solved0%

Step 1 · Read the lesson

Linked List · Fast & Slow Pointers

Rewire pointers carefully; use a fast and slow pointer to find cycles and middles.

Step 2 · Solve the problems in order

Try each one for about 20 minutes first. Problems with a Run code tab are checked right here. If you are stuck, open Nudge, think again, then Idea. Go skeleton only gives the function shape, and Reference solution is for comparing after you have tried. Tick the box when you could solve it again without help.

  1. 1.Reverse Linked ListEasy
  2. 2.Merge Two Sorted ListsEasy
  3. 3.Linked List CycleEasy
  4. 4.Reorder ListMedium
  5. 5.Remove Nth Node From End of ListMedium
  6. 6.Copy List with Random PointerMedium
  7. 7.Add Two NumbersMedium
  8. 8.Find the Duplicate NumberMedium
  9. 9.LRU CacheMedium
  10. 10.Merge k Sorted ListsHard
  11. 11.Reverse Nodes in k-GroupHard

Step 3 · What this unlocks