Prove or disprove that $f: \mathbb{R} \rightarrow \mathbb{R}$ is one-to-one if,
$$f(x) = -3x^2+7$$
Assume $f(x) = f(y)$, then
$$-3x^2+7 = -3y^2+7$$
$$-3x^2 = -3y^2$$
$$x^2 = y^2$$
$$x = y$$
Hence function is one-to-one.
While we can easily see that function is not one-to-one. For example $f(-1)=f(1)$.
Where is the proof wrong?
The proof is wrong because $$x^2=y^2\iff x=\pm y$$ and not just $x=y$.