Solution (source code)

= Solution

In <field characteristic> $p$, the identity matrix has <trace> $p=0$, and hence belongs to $\mathfrak{sl}_p$. Its span is a nonzero proper <central ideal>, so $\mathfrak{sl}_p$ is not a <simple Lie algebra>. In fact its <center of a Lie algebra> is precisely $kI_p$: commuting with every off-diagonal <matrix unit> forces a matrix to be scalar.

For $p>2$, the <matrix-unit extraction lemma for special linear ideals> still works because two is invertible. Any ideal containing a nonscalar matrix contains every off-diagonal <matrix unit> and every trace-zero diagonal matrix, hence equals $\mathfrak{sl}_p$. Therefore an ideal of the <quotient Lie algebra> pulls back either to the center or to the whole algebra. The quotient is nonabelian, since $[E_{12},E_{23}]=E_{13}$ remains nonzero modulo the center. Consequently
$$
\boxed{\mathfrak{sl}_p/kI_p\text{ is simple for }p>2.}
$$
No separation of diagonal <root spaces> is needed, so this proof also handles $p=3$ without assuming their weights are distinct.

For $p=2$, every trace-zero two-by-two matrix has the form $aI+bE_{12}+cE_{21}$. The only nonzero bracket between these basis vectors is $[E_{12},E_{21}]=I$, which is central. Thus
$$
\boxed{\mathfrak{sl}_2/kI\text{ is a two-dimensional abelian Lie algebra in characteristic two.}}
$$