We let $\gamma$ be a simple closed contour, and $f$ analytic in and on $\gamma$. Then how might we show that for any $z$ in the interior of $\gamma$, that the equation $\int_\gamma \frac{f'(w)}{w-z}\,dw = \int_\gamma \frac{f(w)}{(w-z)^2}\,dw$ holds?
My thinking is that we can apply the Cauchy Integral formula on the right hand side to show that it is equal to $2\pi if'(z)$, and it just suffices to show the LHS is equal to this, but am stuck at this step.
I'm interested in general if this holds as well, say $\int_\gamma \frac{f^{(n)}(w)}{w-z}\,dw = \int_\gamma \frac{f(w)}{(w-z)^{n+1}}\,dw$. How might we show the first equality, and then maybe this more general one?
Using the product rule for differentiation, we can write
$$\begin{align} \oint_\gamma \frac{f'(w)}{w-z}\,dw&=\oint_\gamma \left(\frac{d}{dw}\left(\frac{f(w)}{w-z}\right)+\frac{f(w)}{(w-z)^2}\right)\,dw\\\\ &=\oint_\gamma \frac{f(w)}{(w-z)^2}\end{align}$$
as was to be shown!
Note that the integral $\displaystyle \oint_\gamma \frac{d}{dw}\left(\frac{f(w)}{w-z}\right)\,dw=0$ since $\frac{f(w)}{w-z}$ is analytic on $\gamma$ and $\gamma$ is a closed contour.