Solution (source code)

= Solution

For a closed surface, $\chi=V-E+F$ for any finite cell decomposition. Gauss–Bonnet for a geodesic polygon says
$$
\int_DK\,dA+\sum\text{ exterior angles}=2\pi\chi(D),
$$
and for a closed smooth surface it says $\int_SK\,dA=2\pi\chi(S)$.

For a large radius, the graph surface bounded over that circle is flat near its boundary. The boundary geodesic-curvature <integral> is $2\pi$, so Gauss–Bonnet on the disc gives $\int K=0$. Since $K\ge0$, continuity forces $K\equiv0$.

For the torus,
$$
K=\frac{\cos u}{2+\cos u}.
$$
Thus $T_+$ has $\cos u>0$ and $T_-$ has $\cos u<0$. Cap the two boundary circles of the outer half $T_+$ by flat discs. The result is a sphere, and the caps contribute no Gaussian curvature, so Gauss–Bonnet gives $\int_{T_+}K=4\pi$. The full torus has <Euler characteristic> zero, hence total curvature zero and
$$
\boxed{\int_{T_-}K=-4\pi.}
$$