Credits @gaurav_sharma
There is a frog who could climb either 1 stair or 3 stairs in one shot. In how many ways he could reach at 10th stair ?
Fibonacci with a gap of 1 : 1, 1, 2, 3, 4, 6, 9, 13, 19, 28
Answer : 28
Method 2 :1 step in 1 way2 steps in 1 way3 steps in 2 ways4 steps in 3 ways5 steps in 4 ways6 steps in 6 ways7 steps in 9 ways8 steps in 13 ways9 steps in 19 ways10 steps in 28 waysSo 28 should be the answer
Method 3 :
x + 3y = 10(1 , 3 ) -> 4(4 , 2 ) -> 6!/4!2! = 15(7 , 1) -> 8!/7! = 8(10 , 0) -> 1TOTAL = 15 + 4 + 8 + 1 = 28