(i) Let $R$ be an integral domain that has irreducible elements. Prove that $R[X]$ is not A PID.

(ii) Let $R$ be a UFD and $K$ its field of fractions. Let $f \in R[X]$ be a monic polynomial with $\alpha$ a root of $f$ in $K$. Show that $\alpha \in R$.

I think I could prove (i), just in case I've done something wrong, I will write my solution.

Let $a \in R$ irreducible and consider the ideal $\langle a, x \rangle$. Suppose $R[X]$ is PID, then $\langle a, x \rangle=\langle f \rangle$ with $f \in R[X] \setminus \{0\}$.

But then $a=fg, g \in R[X] \setminus \{0\}$. We have $0=\deg(a)=\deg(f)+\deg(g)$. From here it follows $\deg(f)=\deg(g)=0$, so $f,g \in R$. Since $a$ is irreducible, we must have $f \in \mathcal U(R)$ or $g \in \mathcal U(R)$. Notice that $f \not \in \mathcal U(R)$. Suppose this is the case, then $\langle a,x \rangle=R[X]$.

We can write $1=a(a_0+a_1x+\cdots+a_nx^n)+x(b_0+b_1x+\cdots+b_mx^m)$. It folows $1=aa_0$, which means $a$ is a unit, this is absurd by the definition of irreducible element.

On the other hand, we have $x=fh$, so $1=\deg(x)=0+\deg(h)$. Then, $h=bx+c$. Putting this into the equation we get

$$x=f(bx+c)=fbx+fc.$$

So $fc=0 \implies c=0$ and $fb=1$, which means $f \in U(R)$. We've arrived to a contradiction which comes from assuming that $R[X]$ was PID$.

I don't know what to do in (ii), I would really appreciate help with that part.