NK ladder and snake

In the example, Snakes were present at (n -1)th position and (n-4)th position, then you mentioned recursive formula will given as,
F(i) = 0 * F(i-1) + 1 * F(i -2) + 1 * F(i-3)
but if this the case then when we would be computing
F(i - 2) in the recursive process then its formula would become F(i - 2) = 0* F(i - 3) + 1 * F(i - 4) + 1 * F(i - 5)
here we should have made F(i - 4) to be zero because snake is present at that position but instead we are making F(i - 3) to be zero where there is no snake.
So, is this formula correct if so please explain it.

We will have to change coefficients with recursive calls.
You are thinking right that if we keep (0,1,1) in every call, it will result to a wrong answer.
So we change the variables in every call.

I hope I’ve cleared your doubt. I ask you to please rate your experience here
Your feedback is very important. It helps us improve our platform and hence provide you
the learning experience you deserve.

On the off chance, you still have some questions or not find the answers satisfactory, you may reopen
the doubt.

If we have to change the variable in every call then complexity will become k^3n instead of k^3logn this is even more than dp case where it is only n what is the purpose of using this