Show that in a UFD, prime elements are irreducible
Here is what I have so far:
Suppose $p \in R$ is prime, then the ideal it generates is a prime ideal in $R$. If $ab$ (where neither $a$ nor $b$ are zero) belongs to $\langle p \rangle$ then we can say (without loss of generality) that $p = ab$, also by by definition $a \in \langle p \rangle$ or $b \in \langle p \rangle$.
Suppose $a \in \langle p \rangle$, then $a = pr$, then $p = prb$ and so $1 = rb$, i.e. $b$ is a unit. Thus since $p$ is equal to a product in which one of the elements is a unit, $p$ is irreducible.
Is this good?