Give an example if possible, and if not possible explain why not.
a) A subring of a PID that is not PID.
b) A PID that is a subring of a non-PID.
c) A subring of a PID that is not UFD.
My approach:
a) Since $\mathbb{Q}$ is field then $\mathbb{Q}[x]$ is PID. But it's subring $\mathbb{Z}[x]$ is not PID because the ideal $(2,x)$ in $\mathbb{Z}[x]$ is not principal.
b) Consider the subring $\mathbb{Z}$ of the ring $\mathbb{Z}[x]$. We know that $\mathbb{Z}$ is euclidean domain and hence is PID.
c) Consider the subring $\mathbb{Z}[\sqrt{-5}]$ of the ring $\mathbb{Q}[\sqrt{-5}]$. I know that $\mathbb{Z}[\sqrt{-5}]$ is not UFD, but $\mathbb{Q}[\sqrt{-5}]\cong \mathbb{Q}[x]/(x^2+5)$ and since $x^2+5$ is irreducible in $\mathbb{Q}[x]$ then it's field $\Rightarrow$ $\mathbb{Q}[\sqrt{-5}]$ is also field $\Rightarrow$ is PID.
Are my examples correct?
Would be very grateful!