A question from a previous qualifying exam at my university reads:
"Suppose that f and g are entire functions such that $f \circ g(x) = x$ when $x \in \mathbb{R}$. Show that $f$ and $g$ are linear functions."
One can conclude that the composition of $f$ and $g$ is the identity on all of $\mathbb{C}$, by the uniqueness principle. I know how to solve the problem if one assumes that $f$ is injective. However, there are examples of functions that have a right inverse but are not injective. However, entire functions have many properties, so is there a way of showing $f$ must be injective from the information above, or should I approach the problem differently?