Artificial intelligent assistant

Find a and b such that this limit is equal to an answer. $\lim_{n\rightarrow\infty}(a+\frac{n+1}{bn^2+n+2})^{n+2}=\frac1e$ So I tried to get to the common denominator and then add 1 and substract 1 inside the power to create the case $1^\infty$. But I get to something really absurd and wrong. What's wrong with my approach?

Recall that the limit for $e^x$ is as follows:

$$\lim_{n \to \infty} \left(1+{x \over n}\right)^{n}$$

So to achieve $\frac{1}{e}$, $x$ must be $-1$. You get this by using $a=1$ and $b=-1$ and factoring:

$$\require{cancel} \lim_{n\rightarrow\infty}\left(1+\frac{n+1}{-n^2+n+2}\right)^{n+2}=\lim_{n\rightarrow\infty}\left(1+\frac{\cancel{n+1}}{-1(n-2)(\cancel{n+1})}\right)^{n+2}=\lim_{n\rightarrow\infty}\left(1-\frac{1}{n-2}\right)^{n+2}$$

And using some manipulation:

$$\lim_{n\rightarrow\infty}\left(1-\frac{1}{n-2}\right)^{n+2}=\lim_{n\rightarrow\infty}\left[\left(1-\frac{1}{n-2}\right)^{n-2}\right]^{n+2\over n-2}= \left({1 \over e}\right)^1$$

xcX3v84RxoQ-4GxG32940ukFUIEgYdPy 9bbdac4f50153b8231eddfffb81f809a