Solution (source code)

= Solution

Near infinity, $g(z)^2=(z-2)(z^2-1)\sim z^3$, so $g(z)\sim z^{3/2}$. One positive circuit around infinity changes $z^{3/2}$ by the <monodromy> factor $e^{3\pi i}=-1$. Thus analytic continuation does not return to the original value, and \b[$\infty$ is a branch point].