I am calculating the residue of $$ \frac{\sin z}{z^{2}(\pi-z)} $$
Since there is only $1$ pole (simple) at $0$, I went about calculating the residue according to the rule: $$Res\left [ \frac{f(x)}{g(x)}, z_{0} \right ] = \lim_{z\rightarrow z_{0}} \frac{f(x)}{g'(x)}$$
With this formula, I find the residue to be $\frac{1}{2\pi}$. However, the answer is supposed to be $\frac{1}{\pi}$.
Is the formula I have used correct? Or am I making some other mistake?