I want to check if my solutions for this problem are right.
Let $R$ be a factorial ring in which every ideal generated by two elements is a principal ideal.
Show that $R$ is a principal ideal ring.
What I thought is: every element of a factorial Ring $a$can be written as a product of irreducible elements $p_1,...,p_m$. We have $a=p_1\cdots p_m$ moreover $a=br$ for two $b,r \in R$. This means that $a$ is an ideal generated by two elements.
We know therefore that all $a \in R$ are principal ideal. For this exists a common divisor for all elements $a \in R$ so that each $a \in R$ can be written as $a=br$, where $b$ is the common divisor. All elements of $R$ are therefore generated from a common element $b$. This is why $R$ is a principal ideal.
I think that my solution is wrong. Can someone help me?