Help evaluating $\lim_{n\to \infty} \sum_{k=1}^n \frac{e^{\frac{-k}{n}}}{n}$ $$ \lim_{n\to \infty} \sum_{k=1}^n \frac{e^{\frac{-k}{n}}}{n} $$
is what I am asked to evaluate. My working:
\begin{align}
 &= \lim_{n\to \infty} \frac{1}{n}\sum_{k=1}^n e^{\frac{-k}{n}} \\
&= \lim_{n\to \infty} \frac{1}{n} \left( \frac{1}{e^\frac{1}{n}} + \frac{1}{e^\frac{2}{n}} + \frac{1}{e^{\frac{3}{n}}} + \cdots + \frac{1}{e^\frac{n}{n}} \right) \\
&= \lim_{n\to \infty} \frac{1}{n}\frac{1}{e^\frac{1}{n} -1} = \lim_{\frac{1}{n} \to 0} \frac{\frac{1}{n}}{e^\frac{1}{n} -1} \\ &= 1.
\end{align}
Wrong. The answer is $1-\frac{1}{e}$. Where did I go wrong here?

The equality
$$\left( \frac{1}{e^\frac{1}{n}} + \frac{1}{e^\frac{2}{n}} + \frac{1}{e^{\frac{3}{n}}} + \cdots + \frac{1}{e^\frac{n}{n}} \right)=\frac{1}{e^\frac{1}{n} -1}$$
is false. I think what you want to see is a geometric sum
$$\sum_{k=1}^n e^{-k/n} = \sum_{k=1}^n \left(e^{-1/n}\right)^k =\frac{e^{-1/n-1}-1}{e^{-1/n}-1} $$
where the numerator takes the form
$$\lim_{n\to\infty}e^{-1/n-1}-1=\frac{1}{e}-1$$
and by L'Hopital's rule the denominator becomes
$$\lim_{n\to\infty} n \left (e^{-1/n}-1 \right ) = \lim_{n\to\infty}\frac{e^{-1/n}-1}{1/n}=-1$$
