$5 \cdot 6$ If $p(x)$ is an $n$-degree polynomial, and for $k=0,1,2, \cdots, n$, we have $p(k)=\frac{k}{k+1}$, try to determine $p(n+1)$.


[Proof] Let $Q(x) = (x+1) p(x) - x$. From the given conditions, we know that $Q(x)$ is a polynomial of degree no more than $n+1$, and when $x = 0, 1, 2, \cdots, n$, we have $Q(x) = 0$. Therefore, we have
$$
Q(x) = a x(x-1)(x-2) \cdots (x-n),
$$

where $a$ is a constant. That is,
$$
(x+1) p(x) - x = a x(x-1)(x-2) \cdots (x-n)
$$

Let $x = -1$, we get
$$
\begin{array}{l}
1 = a(-1)^{n+1}(n+1)! \\
a = \frac{(-1)^{n+1}}{(n+1)!}
\end{array}
$$

Thus,
$$
\begin{aligned}
p(x) & = \frac{Q(x) + x}{x + 1} \\
& = \frac{\frac{(-1)^{n+1}}{(n+1)!} x(x-1)(x-2) \cdots (x-n) + x}{x + 1}, \\
p(n+1) & = \frac{(-1)^{n+1} + n + 1}{n + 2},
\end{aligned}
$$

which means
$$
p(n+1) = \left\{\begin{array}{l}
1, \text{ if } n \text{ is odd; } \\
\frac{n}{n+2}, \text{ if } n \text{ is even. }
\end{array}\right.
$$