Series for $\frac 1e$ When I read book, I see this:
$$\lim D_n=1-\frac{1}{1!}+\frac{1}{2!}-\cdots+\frac{(-1)^n}{n!}=\frac{1}{e}$$
But I don't know why we have? Can you explain?
 A: The Maclaurin series for $e^x$ is
$$e^x=\sum_{k\ge 0}\frac{x^k}{k!}\;;$$
it’s valid for all $x$. For $x=-1$ this becomes
$$e^{-1}=\sum_{k\ge 0}\frac{(-1)^k}{k!}=1-\frac1{1!}+\frac1{2!}-\frac1{3!}+-\ldots~.$$
Your numbers $D_n$ are just the partial sums of this infinite series.
A: As $$\lim_{n\to \infty}\left(1+\frac1n\right)^n=e$$
$$e^x=\lim_{n\to \infty}\left(1+\frac1n\right)^{nx}=\lim_{n\to \infty}\left(1+\frac{nx}{1!}\frac1n+\frac{nx(nx-1)}{2!}\frac1{n^2}+\frac{nx(nx-1)(nx-2)}{3!}\frac1{n^3}+\cdots\right)$$
The 1st term $t_0=1$
The $r$ th term (where $r\ge1$) $$t_r=\frac{nx(nx-1)\cdots(nx-r+1)}{r!n^r}=\frac1{r!}\prod_{0\le t\le r-1}(x-\frac tn)$$
$$\lim_{n\to \infty}t_r=\frac{x^r}{r!}$$
So, $$e^x=\lim_{n\to \infty}(1+\frac1n)^{nx}=\sum_{0\le r< \infty}\frac{x^r}{r!}$$

Alternatively, let $$y=\sum_{0\le r< \infty}\frac{x^r}{r!}$$
$$\frac{dy}{dx}=\sum_{0\le r< \infty}\frac{rx^{r-1}}{r!}=\sum_{1\le r< \infty}\frac{x^{r-1}}{(r-1)!}=y$$
So, $$\frac{dy}y=dx$$
Integrating we get, $$\ln y= x+c$$
or, $$y=e^{c+x}\implies e^{c+x}=y=\sum_{0\le r< \infty}\frac{x^r}{r!}$$
Putting, $x=0$ we get, $e^c=1\implies c=0\implies e^x=\sum_{0\le r< \infty}\frac{x^r}{r!}$
A: Perhaps the book was talking about Derangements. In this answer it is shown that
$$
\begin{align}
\frac{\mathcal{D}(n)}{n!}
&=\sum_{k=0}^n(-1)^k\frac1{k!}\\
&\approx \frac1e
\end{align}
$$
The series
$$
e^x=\sum_{k=0}^\infty\frac{x^k}{k!}
$$
shows that
$$
\begin{align}
\left|\,e^{-1}-\frac{\mathcal{D}(n)}{n!}\right|
&=\left|\sum_{k=n+1}^\infty(-1)^k\frac1{k!}\right|\\
&\le\frac1{(n+1)!}
\end{align}
$$
