@FernandoMartin When $f:M\to N$ is a surjection, we know each fiber $f^{-1}(n)$, $n\in N$ is nonempty. Then there exists $x_n\in f^{-1}(n)$. Why does it involve choice saying "Now define $g:N\to M$ by $n\to x_n$?
you know the sets $f^{-1}(n)$ are non-empty, but you need to pick $x_n\in f^{-1}(n)$ for each $n$ - that's exactly the same as picking an element in $\Pi f^{-1}(n)$, or as @Karl says, a choice function