Pulsars
0 %
Log inSign up

Adapting the recurrence

Open answer

For the staircase, you could advance by 1 or 2 stairs. If you could also advance by 3 stairs at once, how would the recurrence formula dp[i] = dp[i-1] + dp[i-2] need to be modified?