Evaluate the integral
$$ I=\frac{1}{2\pi i}\int_{\vert z \vert =R}(z-3)\sin\left(\frac{1}{z+2}\right)dz$$
where $R \geq 4$
My work: Here the zeros of $\sin\left(\frac{1}{z+2}\right)$ is $\frac{1}{n \pi}-2$, so $-2$ is non-isolated singularity. But after I am stuck, Please help. Thanks.
The integrand function has just ONE singularity at $z=-2$. For any non-zero integer $n$ then by letting $z=\frac{1}{n \pi}-2$, we have that $$\sin\left(\frac{1}{z+2}\right)=\sin(n\pi)=0.$$
So, for $R>2$, the singularity $z=-2$ is inside the circle $|z|=R$, and, by the Residue Theorem, $$\begin{align}\frac{1}{2\pi i}\int_{\vert z \vert =R}(z-3)\sin\left(\frac{1}{z+2}\right)dz&=\text{Res}\left((z-3)\sin\left(\frac{1}{z+2}\right), -2\right)\quad(w:=z+2)\\ &= \text{Res}\left((w-5)\left(\frac{1}{w}-\frac{1}{3! w^3}+\frac{1}{5! w^5}+\dots\right), 0\right)\\ &= \text{Res}\left(1-\frac{5}{w}-\frac{1}{3! w^2}+\frac{5}{3! w^3}+\dots, 0\right)\\ &=-5. \end{align}$$
P.S. If $0<R<2$ then the above integral is zero.