Determine a positive integer $n\leq5$,such that $\int_{0}^{1}e^x(x-1)^ndx=16-6e$ Determine  a positive integer $n\leq5$,such that $\int_{0}^{1}e^x(x-1)^ndx=16-6e$.
I tried to solve it.But since $n$ is given to be $\leq$ 5,my calculations went lengthy.
Applying integration by parts repeatedly,we get
\begin{align}
\int e^x(x-1)^n \, dx &= \left[(x-1)^ne^x-n(x-1)^{n-1}e^x+n(n-1)(x-1)^{n-2}e^x \right. \\
& \hspace{5mm} \left.-n(n-1)(n-2)(x-1)^{n-3}e^x+n(n-1)(n-2)(n-3)(x-1)^{n-4}e^x \right. \\
& \hspace{5mm} \left.-n(n-1)(n-2)(n-3)(n-4)e^x\right]
\end{align}
\begin{align}
\int_{0}^{1}e^x(x-1)^n \, dx &= -n(n-1)(n-2)(n-3)(n-4)e-(-1)^n+n(-1)^{n-1}-n(n-1)(-1)^{n-2} \\ 
& \hspace{5mm} +n(n-1)(n-2)(-1)^{n-3}-n(n-1)(n-2)(n-3)(-1)^{n-4} \\
& \hspace{5mm} +n(n-1)(n-2)(n-3)(n-4) \\
&=16-6e
\end{align}
Now solving this is very difficult,is there another simple and elegant method to find $n=3.$

HINT:
Let $x-1=y$
$$\int_0^1e^x(x-1)^n\ dx=\int_{-1}^0e^{y+1}y^n\ dy=e\int_{-1}^0e^yy^n\ dy$$
Now integrating by parts, $$I_n=\int_{-1}^0e^yy^n\ dy=[y^n\int e^y\ dy]_{-1}^0-\int_{-1}^0\left(\dfrac{d(y^n)}{dy}\int e^y\ dy\right)dy$$
$\implies I_n=-(-1)^n\dfrac1e-nI_{n-1}$
Now $I_0=\int_{-1}^0e^y\ dy=1-\dfrac1e$
$\implies I_1=\dfrac1e-I_0$  and so on
