Solution (source code)

= Solution
{c}

A <prime ideal> is a proper <ideal> $I\ne R$ such that $ab\in I$ implies $a\in I$ or $b\in I$. A <maximal ideal> is a proper <ideal> $I\ne R$ such that there is no <ideal> strictly between $I$ and $R$.

Every <ideal> of the <integers> has the form $(n)=n\mathbb Z$ for a unique nonnegative integer $n$. Its <prime ideals> and <maximal ideals> are respectively
$$
\boxed{\{(0)\}\cup\{(p):p\text{ prime}\},\qquad
\{(p):p\text{ prime}\}.}
$$
The zero <ideal> is a <prime ideal> because the <integers> form an <integral domain>. For a <prime number> $p$, divisibility of $ab$ by $p$ forces divisibility of one factor, so $(p)$ is a <prime ideal>. Also any <ideal> $(d)$ containing $(p)$ has $d\mid p$, so it equals $(p)$ or $(1)$; thus $(p)$ is a <maximal ideal>.

If $n>1$ is composite, write $n=ab$ with $1<a,b<n$. Then $ab\in(n)$ while neither factor belongs to $(n)$, so $(n)$ is not a <prime ideal>. A <prime number> $p\mid n$ gives $(n)\subsetneq(p)\subsetneq\mathbb Z$, so $(n)$ is not a <maximal ideal> either. The zero <ideal> is not maximal since $(0)\subsetneq(2)\subsetneq\mathbb Z$, and $(1)=\mathbb Z$ is not proper.