TITLE: Nontrivial subring with identity of a ring without identity
QUESTION [6 upvotes]: I'm looking for an example a ring and a subring with $R \subset S$ such that $R$ has 1 but $S$ does not. Its easy to choose R to be the trivial ring with $0=1$, but are there any more exotic examples of this phenomenon?

REPLY [4 votes]: Let K be any nontrivial unital ring.
Let $R = \left\{\left(\begin{smallmatrix} a & 0 \\ 0 & 0 \end{smallmatrix}\right) : a \in K \right\}$, and let $S = \left\{\left(\begin{smallmatrix} a & b \\ 0 & 0 \end{smallmatrix}\right) : a,b \in K \right\}$. Note that, S is a rng under the standard operations in $M_2(K)$ whereas R is a ring with identity $\left(\begin{smallmatrix} 1 & 0 \\ 0 & 0 \end{smallmatrix}\right)$.

REPLY [3 votes]: Let $R$ be your favorite ring with $1$, let $T$ be your favorite ring without $1$, and let $S=R\times T$ (identifying $R$ with $R\times\{0\}\subset S$).  Your trivial example is just the special case of this when $R$ is the trivial ring.