I have a question: Let R be an integral domain, if the only ideals are the trivial ideals, prove that R is a field.
So my proof for this was;
Let $a\in R$ be a non-zero element. Since we have that the only ideals are $(0)$ and $(1)$ we have that $a$ cannot be in $(0)$ since it's non-zero. Since $a$ isn't in $(0)$, it has to be in $(1)$ which implies that $a$ is a multiple of $1$ for some $b$ i.e. $ab = 1$
But this implies that $a$ is a unit so therefore $R$ is a field.
My professor told me there's a better way of doing this. Using the following theorem: Let $R$ be a ring that is commutative with identity and let $M$ be an ideal in $R$. Then $M$ is maximal iff $R/M$ is a field.
Personally, I have no idea how to use this theorem for this proof. It's obvious that $(0)$ is maximal so that means $R/(0)$ is a field. How do I go about showing R is a field using this?