[proofplan]
We compute $H_*(\Sigma_g)$ via the Mayer-Vietoris sequence for the decomposition $\Sigma_g = F_{g-1} \cup_{S^1} F_1$, where $F_k$ denotes the genus-$k$ surface with an open disk removed. The inputs are (i) $H_*(F_k) \cong H_*(X_{2k})$, where $X_{2k}$ is a wedge of $2k$ circles, coming from a deformation retraction of the punctured polygon onto its boundary, and (ii) the known homology of $S^1$. The crux is computing two connecting maps: the map $\phi: H_1(S^1) \to H_1(F_{g-1}) \oplus H_1(F_1)$ vanishes because the boundary circle of each piece traverses each $1$-cell of the rose twice with opposite orientations, and the map $\psi: H_0(S^1) \to H_0(F_{g-1}) \oplus H_0(F_1)$ is injective because the circle maps to a point in each connected component. Exactness then pins down $H_2(\Sigma_g)$ and $H_1(\Sigma_g)$.
[/proofplan]
[step:Set up the Mayer-Vietoris decomposition $\Sigma_g = F_{g-1} \cup_{S^1} F_1$]
Fix $g \geq 1$. (The case $g = 0$ is $\Sigma_0 = S^2$; its homology follows from the [Homology of Spheres](/theorems/1945).) Choose an embedded circle $C \subset \Sigma_g$ that separates $\Sigma_g$ into two compact surfaces with boundary: one of genus $g-1$ with one boundary circle, and one of genus $1$ with one boundary circle. Write $F_{g-1}$ and $F_1$ for slight open thickenings of these pieces (take the pieces together with open collar neighbourhoods of $C$), so that $F_{g-1}$ and $F_1$ are open in $\Sigma_g$, $\Sigma_g = F_{g-1} \cup F_1$, and the intersection $F_{g-1} \cap F_1$ deformation retracts onto $C \cong S^1$.
Both $F_{g-1}$ and $F_1$ deformation retract onto the closed punctured surfaces of genus $g-1$ and $1$ respectively, and the pair $\{F_{g-1}, F_1\}$ is an open cover of $\Sigma_g$ whose pairwise intersection is homotopy equivalent to $S^1$. This is the open-cover setup required by the [Mayer-Vietoris Theorem](/theorems/1931).
[/step]
[step:Record the homology of the punctured pieces and of the interface circle]
By the [Homology of the Punctured Surface](/theorems/1952), the genus-$k$ punctured surface is homotopy equivalent to the rose $X_{2k}$ (the wedge of $2k$ circles), so
\begin{align*}
H_n(F_k) \cong \begin{cases} \mathbb{Z} & n = 0, \\ \mathbb{Z}^{2k} & n = 1, \\ 0 & n \geq 2. \end{cases}
\end{align*}
Specialising to $k = g-1$ and $k = 1$:
\begin{align*}
H_0(F_{g-1}) \oplus H_0(F_1) &\cong \mathbb{Z} \oplus \mathbb{Z}, \\
H_1(F_{g-1}) \oplus H_1(F_1) &\cong \mathbb{Z}^{2(g-1)} \oplus \mathbb{Z}^2 \cong \mathbb{Z}^{2g}, \\
H_n(F_{g-1}) \oplus H_n(F_1) &= 0 \text{ for } n \geq 2.
\end{align*}
The homology of the interface $S^1$ is $H_0(S^1) \cong \mathbb{Z}$, $H_1(S^1) \cong \mathbb{Z}$, and $H_n(S^1) = 0$ for $n \geq 2$ (a rose with one circle, or the [Homology of the Punctured Surface](/theorems/1952) with $k = 0$ applied to $F_0 \simeq \text{pt}$ replaced by the direct computation for $S^1$ as $X_1$).
[/step]
[step:Write down the Mayer-Vietoris long exact sequence with these groups inserted]
Applying the [Mayer-Vietoris Theorem](/theorems/1931) to the cover $\{F_{g-1}, F_1\}$ of $\Sigma_g$ and substituting the groups from the previous step gives the long exact sequence
\begin{align*}
0 \to H_2(\Sigma_g) \xrightarrow{\partial} H_1(S^1) \xrightarrow{\phi} H_1(F_{g-1}) \oplus H_1(F_1) \to H_1(\Sigma_g) \to H_0(S^1) \xrightarrow{\psi} H_0(F_{g-1}) \oplus H_0(F_1) \to H_0(\Sigma_g) \to 0,
\end{align*}
and $H_n(\Sigma_g) = 0$ for $n \geq 3$ (the groups on either side of $H_n(\Sigma_g)$ in the sequence vanish for $n \geq 3$). With explicit groups,
\begin{align*}
0 \to H_2(\Sigma_g) \xrightarrow{\partial} \mathbb{Z} \xrightarrow{\phi} \mathbb{Z}^{2g} \to H_1(\Sigma_g) \to \mathbb{Z} \xrightarrow{\psi} \mathbb{Z}^2 \to H_0(\Sigma_g) \to 0.
\end{align*}
Since $\Sigma_g$ is path-connected, $H_0(\Sigma_g) \cong \mathbb{Z}$.
[/step]
[step:Show $\phi: H_1(S^1) \to H_1(F_{g-1}) \oplus H_1(F_1)$ is the zero map]
The map $\phi$ is the difference $(i_{g-1})_* - (i_1)_*$ of the maps on $H_1$ induced by the inclusions $i_{g-1}: S^1 \hookrightarrow F_{g-1}$ and $i_1: S^1 \hookrightarrow F_1$ (the two sides of the Mayer-Vietoris decomposition). It suffices to show that each inclusion $i_k: S^1 \hookrightarrow F_k$ sends the generator of $H_1(S^1) \cong \mathbb{Z}$ to $0 \in H_1(F_k) \cong \mathbb{Z}^{2k}$.
By the [Homology of the Punctured Surface](/theorems/1952), $F_k$ deformation retracts onto the rose $X_{2k}$, where the retraction is induced by the polygon model: $F_k$ is the $4k$-gon with interior disk removed and edge identifications $a_1 b_1 a_1^{-1} b_1^{-1} \cdots a_k b_k a_k^{-1} b_k^{-1}$, and the retraction pushes the punctured polygon radially out to its boundary edge-cycle. Under this retraction, the boundary circle $\partial F_k$ maps to the boundary word of the polygon, traversed once.
In $H_1(X_{2k}) \cong \mathbb{Z}^{2k}$, with basis $\{[a_1], [b_1], \ldots, [a_k], [b_k]\}$, the homology class of the boundary word is
\begin{align*}
\sum_{j=1}^{k} \bigl([a_j] + [b_j] - [a_j] - [b_j]\bigr) = 0,
\end{align*}
since each $a_j$ appears once with each orientation (once as $a_j$, once as $a_j^{-1}$), and similarly for $b_j$. Hence $(i_k)_*([S^1]) = 0$ in $H_1(F_k)$.
Since both components of $\phi$ vanish, $\phi = 0$.
[guided]
The map $\phi$ in Mayer-Vietoris measures how the generator of $H_1(S^1)$ — the fundamental class $[S^1]$ of the interface — embeds into each side of the decomposition. Concretely, $\phi([S^1]) = \bigl((i_{g-1})_*[S^1], -(i_1)_*[S^1]\bigr)$ (the sign convention is a Mayer-Vietoris artefact; what matters is that $\phi = 0$ iff both inclusions kill $[S^1]$).
Why would $(i_k)_*[S^1] = 0$? Recall the geometric picture of $F_k$: it is a $4k$-gon with its interior disk removed and with edges pairwise identified according to the standard word
\begin{align*}
w_k = a_1 b_1 a_1^{-1} b_1^{-1} \cdots a_k b_k a_k^{-1} b_k^{-1}.
\end{align*}
The deformation retraction $F_k \simeq X_{2k}$ (cited from the [Homology of the Punctured Surface](/theorems/1952)) is the concrete map that expands the puncture outward until the remaining material collapses onto the polygon's boundary. Under this retraction, the inner boundary circle $\partial F_k$ traces out the polygon boundary, which in $X_{2k}$ reads the word $w_k$.
In the rose $X_{2k}$, each petal $a_j$ or $b_j$ is a loop based at the common vertex. The map $H_1$ is the abelianisation of the fundamental group (for a wedge of circles, $H_1$ is already the free abelian group on the petals), so the word $w_k$ contributes the homology class
\begin{align*}
\sum_{j=1}^k \bigl([a_j] + [b_j] + [a_j^{-1}] + [b_j^{-1}]\bigr) = \sum_{j=1}^k \bigl([a_j] + [b_j] - [a_j] - [b_j]\bigr) = 0.
\end{align*}
The cancellation is the algebraic shadow of the orientability of $\Sigma_g$: closing up the polygon along the word $w_k$ requires each edge to be traversed with both orientations, and in an abelian group those contributions annihilate.
Hence $(i_k)_*[S^1] = 0$ for each $k$, so $\phi = 0$. This vanishing is the geometric heart of the computation — it is where orientability enters. (For the non-orientable surfaces $E_n$, the analogous boundary word has some edges traversed in the same orientation twice, so the corresponding $\phi$ is multiplication by $\pm 2$, and the exact sequence analysis delivers a $\mathbb{Z}/2$ factor instead.)
[/guided]
[/step]
[step:Deduce $H_2(\Sigma_g) \cong \mathbb{Z}$ from exactness at $H_1(S^1)$]
Since $\phi = 0$, exactness at $H_1(S^1) \cong \mathbb{Z}$ gives
\begin{align*}
\operatorname{image}(\partial) = \ker(\phi) = H_1(S^1) \cong \mathbb{Z}.
\end{align*}
The map $\partial: H_2(\Sigma_g) \to H_1(S^1)$ is also injective: exactness at $H_2(\Sigma_g)$ with $H_2(F_{g-1}) \oplus H_2(F_1) = 0$ on the left says $\ker(\partial)$ equals the image of the (zero) map from $H_2(F_{g-1}) \oplus H_2(F_1) = 0$, so $\ker(\partial) = 0$. Therefore $\partial$ is an injection onto $H_1(S^1) \cong \mathbb{Z}$, i.e.\ an isomorphism, and
\begin{align*}
H_2(\Sigma_g) \cong \mathbb{Z}.
\end{align*}
[/step]
[step:Show $\psi: H_0(S^1) \to H_0(F_{g-1}) \oplus H_0(F_1)$ is injective]
Both $F_{g-1}$ and $F_1$ are path-connected (each is homotopy equivalent to a rose, which is path-connected), so $H_0(F_{g-1}) \cong \mathbb{Z}$ and $H_0(F_1) \cong \mathbb{Z}$, each generated by the class of any point. The interface $S^1$ is also path-connected, and its inclusion into each of $F_{g-1}$, $F_1$ sends the generator $1 \in H_0(S^1) \cong \mathbb{Z}$ to the generator of $H_0(F_k) \cong \mathbb{Z}$ (the class of a point). With the Mayer-Vietoris sign convention,
\begin{align*}
\psi(1) = \bigl((i_{g-1})_*(1), -(i_1)_*(1)\bigr) = (1, -1) \in \mathbb{Z} \oplus \mathbb{Z}.
\end{align*}
Since $(1, -1) \neq 0$, $\psi$ is injective.
[/step]
[step:Extract $H_1(\Sigma_g) \cong \mathbb{Z}^{2g}$ from exactness]
Exactness at $H_0(S^1)$ and the injectivity of $\psi$ give $\ker(\psi) = 0$. Tracing back in the sequence, the map $H_1(\Sigma_g) \to H_0(S^1)$ has image $\ker(\psi) = 0$, hence is the zero map. Exactness at $H_1(\Sigma_g)$ then implies the preceding map
\begin{align*}
j: H_1(F_{g-1}) \oplus H_1(F_1) \to H_1(\Sigma_g)
\end{align*}
is surjective.
Exactness at $H_1(F_{g-1}) \oplus H_1(F_1) \cong \mathbb{Z}^{2g}$ identifies
\begin{align*}
\ker(j) = \operatorname{image}(\phi) = \operatorname{image}(0) = 0,
\end{align*}
so $j$ is also injective. Hence $j$ is an isomorphism and
\begin{align*}
H_1(\Sigma_g) \cong H_1(F_{g-1}) \oplus H_1(F_1) \cong \mathbb{Z}^{2g}.
\end{align*}
[/step]
[step:Collect the conclusions and read off higher homology]
Combining the previous steps, together with path-connectedness of $\Sigma_g$ (giving $H_0(\Sigma_g) \cong \mathbb{Z}$) and the vanishing of $H_n(S^1)$ and $H_n(F_k)$ for $n \geq 2$ (which forces $H_n(\Sigma_g) = 0$ for $n \geq 3$ by exactness), we conclude
\begin{align*}
H_n(\Sigma_g) \cong \begin{cases} \mathbb{Z} & n = 0 \text{ or } n = 2, \\ \mathbb{Z}^{2g} & n = 1, \\ 0 & n > 2, \end{cases}
\end{align*}
which is the statement of the theorem. For the base case $g = 0$, we have $\Sigma_0 = S^2$ and the conclusion reduces to the [Homology of Spheres](/theorems/1945).
[/step]