How to show that $\int_R f(z)dz=0?$ Let $f$ be holomorphic in a neighbourhood of a closed rectangle $R$ except for finitely many points $z_0, z_1, \cdots, z_n \in int(R)$ and suppose that $$lim_{z\to z_j}(z-z_j)f(z)=0$$
Then how to show that $\int_{\delta R} f(z)dz=0?$
I am not able to think how to approach this question. Any help will be appreciated.
 A: Take $\epsilon$ so small that $B(z_j,\delta) \subset int(R)$ for $j=1,2,……,n$.Then by Cauchy integral formula on multiple connected domain,we have
$$\int_{R}f(z)dz = \int_{\partial B(z_1,\delta)}f(z)dz + …… + \int_{\partial B(z_n,\delta)}f(z)dz$$
Next we prove that $\int_{\partial B(z_j,\delta)}f(z)dz=0$ for $j=1,2,……,n$.
Since $\lim_{z \to z_j}(z-z_j)f(z)=0$,then for any $\epsilon \gt 0$,there exists $r \lt 0$ such that $|z-z_j|\lt r$ implies $|(z-z_j)f(z)| \lt \epsilon$.Choose $\delta \lt r$ that $$|\int_{\partial B(z_j,\delta)}f(z)dz| = |\int_{\partial B(z_j,\delta)} \frac{(z-z_j)f(z)}{z-z_j}dz| = |\int_{0}^{2\pi} \frac{\delta e^{i\theta}f(z_j+\delta e^{i\theta})}{\delta e^{i\theta}}i\delta e^{i\theta}d\theta| \le \int_{0}^{2\pi}\epsilon d\theta =2\pi \epsilon$$
Hence $\int_{\partial B(z_j,\delta)}f(z)dz=0$.
Consequently $\int_{R}f(z)dz=0$
A: All singularities are of order $1$, i.e.
$$Res_{z=z_j}(f):=\lim_{z\to z_j}(z-z_j)f(z).$$
Since $$\int_R f(z)dz=2\pi i\sum_{j=0}^nRes_{z=z_j}(f),$$
you obviously have the result.
A: It suffices you prove this when there is exactly one such singularity and it is the origin. Note that if we take a ball $B$ in the interior of $R$, by Cauchy's theorem we can eliminate the integral along the boundary of $R\smallsetminus B$, and it remains to show that $$\int_{\partial B} f(z)dz=0$$ 
By hypothesis, given $\varepsilon >0$ we can choose $\delta >0$ so that $|f(z)z|<\varepsilon$ whenever $|z|<\delta$. Now take $B$ of radius $<\delta$, and note that the integral above is $$\int_{\partial B}zf(z)z^{-1}dz$$
By our estimation this is at most $$\varepsilon \int_{\partial B} \left|\frac{dz}z\right|=2\pi \varepsilon$$
in absolute value. Since $\varepsilon >0$ was arbitrary, we can conclude.
