Can someone please explain how to do this? I don’t need the answer I just don’t know how to solve it.

Let [tex]P[/tex] be the number of plain cakes sold, and [tex]D[/tex] the number of decorated cakes sold.
Each plain cake sells for $7, so [tex]P[/tex] cakes sells for [tex]\$7P[/tex].
Similarly, each decorated cakes goes for $11, so [tex]D[/tex] cakes are worth [tex]\$11D[/tex].
The baker sells all but 3 cakes, so
[tex]P + D = 117[/tex]
After the sale, the baker earns a total of $991, so
[tex]7P + 11D = 991[/tex]
Now just solve the system of equations for [tex]P[/tex] and [tex]D[/tex]. This is easily done by substitution or elimination.
(The selected answer is actually the correct one.)