In a board game, dice can roll either $1, 2, 3, 4, 5$ or $6$. The board has $N$ number of space. Every time of dice roll randomly, pawn moves forward exactly to dice rolled a number. Now the problem is how many possible ways or combination of jump can be possible to reach start to end point of a board? For an example end point is 100:
1+2+6+...+1 = 100 -> 1 way
1+3+1+...+3 = 100 -> 2 ways
...
i+i+....+i = 100 -> N ways
Is there any algorithm of recursion?
Suppose in the beginning, the pawn is at position $0$ and the end position is $N$. Let $f(i)$ denote the number of ways to reach position $i$. Then the following relationships hold. $$ f(i) = \begin{cases} f(i-1) + f(i-2) + f(i-3) + f(i-4) + f(i-5) + f(i-6)\ &\text{if }\ i \geq 6 \\ f(4) + f(3) + f(2) + f(1) + f(0) &\text{if }\ i = 5\\ f(3) + f(2) + f(1) + f(0) &\text{if }\ i = 4\\ f(2) + f(1) + f(0) &\text{if }\ i = 3\\ f(1) + f(0) &\text{if }\ i = 2\\ f(0) &\text{if }\ i = 1\\ 1 &\text{if }\ i = 0 \end{cases} $$ The rationale is as follows. Without loss of generality, suppose $i \geq 6$. To reach $i$-th position, you can
first reach $(i-1)$-th position, and the result of dice roll is $1$;
first reach $(i-2)$-th position, and the result of dice roll is $2$;
$\cdots$
first reach $(i-6)$-th position, and the result of dice roll is $6$.
Algorithm. Given the relationships, it is easy to compute $f(N)$. Starting with $i = 1$, you compute $f(i)$ in increasing order of $i$ using the formulas above.