Let $f$ be a function from $X$ to $Y$
Prove that the function $f$ is one-to-one if and only if $f^{-1}(y)$ contains at most one element for every $y \in Y$.
(Note: if this is a duplicate please tell me how you searched to find the original question. Thank you).