Show that $f(z)$ is one-to-one on $\mathbb{D}=\{|z|<1\}$. 
Let $f(z)$ be an analytic function on the open unit disk $\mathbb{D}=\{|z|<1\}$.  Suppose there is an annulus $U = \{r<|z|<1\}$ such that the restriction of $f(z)$ to $U$ is one-to-one.  Show that $f(z)$ is one-to-one on $\mathbb{D}$.

This question is actually a duplicate: Question Relating with Open Mapping Theorem for Analytic Functions
But please don't mark this as a duplicate since it does not have an answer. I even don't understand the hint. I don't understand how to use the Argument principle to find such $n$. Can somebody please help me?
 A: There are a couple of approaches. Here is one.
Let $\gamma$ be the image under $f$ of the circle $|z| = \rho$ for some $r < \rho < 1$. By assumption, $\gamma$ is a simple closed curve (which we can take positively oriented), so $\gamma$ separates $\mathbb{C}$ into two domains: a bounded domain $\Omega$ (the interior of $\gamma$) and an unbounded domain $\Omega'$. Also, $f$ maps $\mathbb{D}_\rho = \{ z : |z| < \rho \}$ into $\Omega$.
Now, take $p$ in $\mathbb{D}_\rho$. Then the number of solutions (with multiplicities) to $f(z) = f(p)$ inside $|z| = \rho$ is given by
$$
\frac{1}{2\pi i} \int_{|\zeta| = \rho} \frac{f'(\zeta)}{f(\zeta)-f(p)}\,d\zeta
$$
(since $\dfrac{f'(\zeta)}{f(\zeta)-f(p)}$ has a simple pole with residue $k$ at points where $f(\zeta)-f(p)$ has a $k$-fold zero). On the other hand, a change of variables ($z = f(\zeta)$) shows that
$$
\frac{1}{2\pi i} \int_{|\zeta| = \rho} \frac{f'(\zeta)}{f(\zeta)-f(p)}\,d\zeta =
\frac{1}{2\pi i} \int_{\gamma} \frac{1}{z-f(p)}\,dz
$$
which is the winding number of $\gamma$ around $f(p) \in \Omega$, and hence equals $1$.
This shows that $f$ is injective on $\mathbb{D}_\rho$. Let $\rho \to 1$ to finish off.
