# Attempted proof of primality (basic)

This is my attempt to prove the following (excerpt from the exercises in my textbook):

Let $$p$$ be an integer other than $$0, \pm 1$$ with this property: Whenever $$b$$ and $$c$$ are integers such that $$p \vert bc$$, then $$p\vert b$$ or $$p\vert c$$. Prove that $$p$$ is prime.

Here is my attempt:

If $$d\vert p$$ then we have $$p=dt$$ for some $$t\in \mathbb Z$$. This implies that $$p\vert d$$ or $$p\vert t$$. If $$p\vert d$$ then $$\vert p \vert \leq \vert d \vert$$ and since we have assumed $$d \vert p$$ we have $$\vert d \vert \leq \vert p \vert$$. This implies that $$\vert d \vert = \vert p \vert$$ so $$d= \pm p$$.

If $$p$$ does not divide $$d$$ then $$p \vert t$$ which implies $$\vert p \vert \leq \vert t \vert$$. Together with $$p=dt$$ this implies that $$d=\pm 1$$. This shows that the only possible divisors of $$p$$ are $$\pm 1$$ and $$\pm p$$, meaning that $$p$$ is prime.

I would greatly appreciate any constructive feedback/criticism on my attempted proof.

• thanks, I'll edit Mar 8 '19 at 1:08

I have trouble understanding your logic, but here is my version. Assume on the contrary that $$p$$ is not prime, then $$p=rs$$, now p|rs implies $$p|r$$ or $$p|s$$, but both are false.
• I believe if $p$ is not prime, then $p=rs$ does not imply $p\vert r$ or $p\vert s$ consider $p=12$, $r=3$ and $s=4$. Then we have $12=3 \cdot 4$, but $12$ does not divide $3$ and $12$ does not divide $4$. Mar 8 '19 at 11:41