Solution (source code)

= Solution

For the <zero ideal>, choose $d=0$. Otherwise choose a nonzero $d\in I$ for which the <Euclidean function> $\delta(d)$ is minimal; the <well-ordering principle> guarantees such a choice. For any $a\in I$, perform Euclidean division:
$$
a=qd+r,\qquad r=0\ \text{or}\ \delta(r)<\delta(d).
$$
Because $I$ is an <ideal>, $r=a-qd\in I$. A nonzero remainder would contradict the minimal choice of $d$, so $r=0$ and $a\in Rd$. Thus $I\subseteq Rd$. Conversely, $d\in I$ implies $Rd\subseteq I$, proving
$$
\boxed{I=Rd.}
$$
Every <ideal> is therefore a <principal ideal>; in particular, a <Euclidean domain> is a <principal ideal domain>.