I have met this problem in elementary set theory which states
With $\mathbb{N}$ the set of nonnegative integers, show that the function $f: \mathbb{N} \rightarrow \mathbb{N}$ given by $n \mapsto n^2$ has no right inverse and exhibit explicitly two left inverses.
I really have no idea how to prove $f$ has no right inverse here and need help. Thanks all!
Assume $g$ is a left inverse. This would mean that $\forall n\in\Bbb{N} n=f(g(n))=\left(g(n)\right)^2$ which means that any integer is a square. A contradiction