Pattern Recognition Drill
Medium Graphs
The Problem
Find minimum dice rolls to reach square 100 on a snakes-and-ladders board.
What approach would you use?
Think about it before scrolling down.
Model board as graph. BFS from square 1. Each node has edges to squares +1 through +6 (with redirects). O(n).
Common Trap
This IS a graph problem in disguise. The key insight is modeling the board as a graph.