Integral extensions of rings, when one of the rings is a field

The following is from page 61 of Introduction to Commutative Algebra by Atiyah & Macdonald:

Proposition 5.7. Let $A\subseteq B$ be integral domains, $B$ is integral over $A$. Then $B$ is a field if and only if $A$ is a field.

I am curious what happens if we drop the hypothesis of "integral domains". It will probably be false (since the hypothesis plays a role in the proof). Thus my question is:

What would be example of $A\subseteq B$ commutative rings such that $B$ is integral over $A$ and

a) $A$ is a field, but $B$ is not a field.

b) $B$ is a field, but $A$ is not a field.

Let me say a word about a). I think the situation a) is actually impossible. Because it seems to me that in the proof of this direction, only $A$ being integral domain is used. Thus, if $A$ is a field (in particular integral domain), then $B$ must also be a field. Edit: As Ted shows, I was wrong. The situation (a) is possible.

Thanks for your time. :)


Solution 1:

If $A \subset B$ and $B$ is a field, then $A$ must at least be an integral domain (subrings of fields are integral domains). So (b) is impossible.

(a) is possible, though. For example, if $A$ is a field then $B = A[x]/(x^2)$ is a ring which is a finitely generated $A$-module and therefore integral over $A$. But $B$ is not a field.