Let $n \in \mathbb{N}_{\geq 2}$. Prove that the following statements are equivalent
(1) For every $x \in \mathbb{Z}_n,$ if $x^2 \equiv 0,$ then $x \equiv 0.$
(2) There is no prime $p$ such that $p^2 | n.$
To prove (1) $\implies$ (2), I attempted $\lnot (2) \implies \lnot (1).$
So, I assumed that there does exist some prime $p$ such that $p^2|n.$ Since the statement should be true for all $n \geq 2,$ it seemed ok to me to specify a particular case: $n = 5.$
Here, $5^2|25.$ Also, $5^2 \equiv 0$ but $5 \not\equiv 0.$
Does such a counter example work to prove this? I have a lot of doubt.
Thank you