The recurrence is: You pick the cheaper route. The final answer is min(dp[n-1], dp[n-2]) because you can take a final jump from either of the last two steps to reach the top (index n).
This mirrors Fibonacci's structure but replaces addition with min and considers costs. This time, you're reducing cost instead of counting! This transition captures the relationship between subproblems.