Show that $f$ has exactly one zero on the square $Q =$ {$x + iy ∈ \Bbb C : |x| < 1, |y| < 1$}. Let $f(z) = z + g(z)$ where $g$ is holomorphic. Suppose that
$|\operatorname{Im} g(z)| < 1$ for $z ∈ [−1 − i, 1 − i]∪[−1 + i, 1 + i]$ and $|\operatorname{Re} g(z)| < 1$ for $z ∈ [−1 − i, −1 + i] ∪ [1 − i, 1 + i]$. 
Show that $f$ has exactly one
zero on the square $Q =$ {$x + iy ∈ \Bbb C : |x| < 1, |y| < 1$}.
My attempt:
I let $h(z) = z$. Then, I want to compare $|g(z)|$ and $|h(z)|$ because if $|g(z)| < |h(z)|$ then by Rouché's theorem, $h$ and $h+g$ have the same number of zeros, and $h$ has in fact one zero. But then $h+g = f$ and thus $f$ would also have the same number of zeros as $h+g$ which has one zero.
This is what I could come up with:
$|g(z)| = |u(z) + iv(z)|$. Then for $z \in Q$, we have $|g(z)| \leq |u(z)| + |v(z)| < 1 + 1 = 2$ (since $|\operatorname{Im} g(z)| < 1$ for $z ∈ [−1 − i, 1 − i]∪[−1 + i, 1 + i]$ and $|\operatorname{Re} g(z)| < 1$ for $z ∈ [−1 − i, −1 + i] ∪ [1 − i, 1 + i]$)
But I don't know how to continue from here. Any help please? 
 A: For this problem the following stronger version of Rouche works (sometimes it is called the symmetric Rouche and is expressed as $|f-g| <|f|+|g|, z \in K$): 
If $\Omega$ is the interior domain of a Jordan curve $K$ and $f(z)+\lambda h(z) \ne 0, \lambda \ge 0, h(z) \ne 0, z \in K$ then $f,h$ have the same number of zeroes inside $\Omega$.
The hypothesis of the OP shows that for $\lambda \ge 0, \Re (f+\lambda z) \ne 0$ when $\Re z = \pm 1$ and $\Im (f+\lambda z) \ne 0, \Im z = \pm 1$ so $f+\lambda z \ne 0$ on the boundary of the square for any $\lambda \ge 0$ while $z \ne 0$ there clearly, so $f,z$ have same number of zeroes inside the square as the OP predicted.
The stronger version of Rouche follows because the homotopy $tf(z)+(1-t)h(z), 0 \le t \le 1, z \in K$ avoids zero by hypothesis ($t=0$ is $h \ne 0$, $1 \ge t>0$ is $f+\frac{1-t}{t}h \ne 0$) so the winding number of $tf(z)+(1-t)h(z)$ around $K$ exists and is continuos for $0 \le t \le 1$ but it is then constant being an integer; at the two ends we get the number of zeroes inside $K$ of $f$ and $g$ respectively
A: An alternative is to use the argument principle.
Short version: Let $\gamma$ be a parameterization of $\partial Q$ with positive orientation. The restrictions on $g$ imply that $f$ maps the right/top/left/bottom edge of the square into the right/upper/left/lower halfplane, respectively.
It follows that $\Gamma = f \circ \gamma$ surrounds the origin exactly once, and therefore
$$
 1 = \frac{1}{2 \pi i} \int_\Gamma \frac{dw}{w} = \frac{1}{2 \pi i} \int_\gamma \frac{f'(z)}{f(z)} \, dz = Z
$$
where $Z$ is the number of zeros of $f$ inside the contour $\gamma$.
Details: Let $\gamma_1, \gamma_2, \gamma_3, \gamma_4: [0, 1] \to \Bbb C$ be parameterizations of the right/top/left/bottom edge of the square such that $\gamma = \gamma_1 + \gamma_2 + \gamma_3 + \gamma_4$ has positive orientation.
Let $\Gamma_j = f \circ \gamma_j$ ($j=1,2,3,4$) and $\Gamma = \Gamma_1 + \Gamma_2 + \Gamma_3 + \Gamma_4$.
The argument principle states that the number of zeros of $f$ in $Q$ is
$$
 Z = \frac{1}{2 \pi i} \int_\gamma \frac{f'(z)}{f(z)} \, dz = \frac{1}{2 \pi i} \int_\Gamma \frac{dw}{w}
$$
so that it remains to show that the winding number
$$
 N(\Gamma, 0) = \frac{1}{2 \pi i} \int_\Gamma \frac{dw}{w}
$$
of $\Gamma$ with respect to the origin is equal to one.
The restrictions on $g$ imply that the image of $\Gamma_1$/$\Gamma_2$/$\Gamma_3$/$\Gamma_4$ is contained in the right/upper/left/lower halfplane, respectively. For example,
$$
  \operatorname{Re}\Gamma_1(t) \operatorname{Re}f(\gamma_1(t)) = 1 +  \operatorname{Re}g(\gamma_1(t)) > 1 + (-1) = 0 \, .
$$
The idea is that $\Gamma$ 


*

*moves from the fourth quadrant to the first quadrant within the right halfplane,

*then from the first quadrant to the second quadrant within the upper halfplane,

*then from the second quadrant to the third quadrant within the left halfplane,

*and finally from the third quadrant to the fourth quadrant within the lower halfplane,


so that it “surrounds” the origin exactly once, i.e. the $N(\Gamma, 0) = 1$.
To make this precise, we define two holomorphic branches of the logarithm:
$$
 L_1: \Bbb C \setminus (-\infty, 0] \to \Bbb C, L_1(z) = \log |z| + i \arg(z)  \text{ with } -\pi < \arg z < \pi \,, \\
 L_2: \Bbb C \setminus [0, \infty) \to \Bbb C, L_2(z) = \log |z| + i \arg(z)  \text{ with } 0 < \arg z < 2 \pi \,. 
$$
Note that both $L_1$ and $L_2$ are antiderivatives of $1/z$ in their respective domains. Denote the images of the four corners of the square with
$$
 a = \Gamma_4(1) = \Gamma_1(0)  \quad \text{(in the fourth quadrant)} \\
 b = \Gamma_1(1) = \Gamma_2(0)  \quad \text{(in the first quadrant)} \\
 c = \Gamma_2(1) = \Gamma_3(0)  \quad \text{(in the second quadrant)}\\
 d = \Gamma_3(1) = \Gamma_3(0)  \quad \text{(in the third quadrant)}
$$
We then have
$$
  \int_\Gamma \frac{dw}{w} = \sum_{j=1}^4  \int_{\Gamma_j} \frac{dw}{w} \\
  = \bigl(L_1(b) - L_1(a) \bigr)
  + \bigl(L_1(c) - L_1(b) \bigr)
  + \bigl(L_2(d) - L_2(c) \bigr)
  + \bigl(L_1(a) - L_1(d) \bigr) \\
= L_2(d) - L_1(d) = 2 \pi i 
$$
and that is exactly the desired result.

With respect to your attempt: The conclusion
$$
|g(z)| \leq |u(z)| + |v(z)| < 1 + 1 = 2
$$
is wrong because the estimates $|u(z)| < 1$ and $|v(z)|< 1$ hold on different parts of the boundary and not simultaneously.
