c = number of children
s = number of students
a = number of adults
since the theater has a capacity of 189, then c + s + a = 189.
there are half as many "a" as "c", so then a = c/2 or 2a = c.
so the cost for all children since the price for one is 5 bucks, the total will be 5*c or 5c.
likewise, the total cost for students is 7*s or 7s.
and for adults likewise is 12*a or 12a.
we know all ticket sales was 1372, so then 5c + 7s + 12a = 1372.

now, let's use the elimination method on that system of equations of two variables, let's multiply hmmmm say the first equation by -7, to eliminate the "s".
![\bf \begin{array}{llll} 3a+s=189&\times -7\implies &-21a-7s=-1323\\ 22a+7s=1372&&~~22a+7s=1372\\ \cline{3-3} &&~~ ~~ a+~~0=49 \end{array} \\\\\\ a=49\qquad \qquad \stackrel{\textit{recall c = 2a}}{c=98} \\\\\\ \stackrel{\textit{and plugging \underline{a} in the 1st equation}}{3(49)+s=189}\implies 147+s=189\implies s=42 \\\\[-0.35em] \rule{34em}{0.25pt}\\\\ ~\hfill a=49\qquad c=98\qquad s=42~\hfill](https://tex.z-dn.net/?f=%5Cbf%20%5Cbegin%7Barray%7D%7Bllll%7D%203a%2Bs%3D189%26%5Ctimes%20-7%5Cimplies%20%26-21a-7s%3D-1323%5C%5C%2022a%2B7s%3D1372%26%26~~22a%2B7s%3D1372%5C%5C%20%5Ccline%7B3-3%7D%20%26%26~~%20~~%20a%2B~~0%3D49%20%5Cend%7Barray%7D%20%5C%5C%5C%5C%5C%5C%20a%3D49%5Cqquad%20%5Cqquad%20%5Cstackrel%7B%5Ctextit%7Brecall%20c%20%3D%202a%7D%7D%7Bc%3D98%7D%20%5C%5C%5C%5C%5C%5C%20%5Cstackrel%7B%5Ctextit%7Band%20plugging%20%5Cunderline%7Ba%7D%20in%20the%201st%20equation%7D%7D%7B3%2849%29%2Bs%3D189%7D%5Cimplies%20147%2Bs%3D189%5Cimplies%20s%3D42%20%5C%5C%5C%5C%5B-0.35em%5D%20%5Crule%7B34em%7D%7B0.25pt%7D%5C%5C%5C%5C%20~%5Chfill%20a%3D49%5Cqquad%20c%3D98%5Cqquad%20s%3D42~%5Chfill)