Maths Olympiad Prep

Library / /187 of 520

Algebra Difficulty 2.7 Junior Find the answer

On the last day of school, Mrs. Wonderful gave jelly beans to her class. She gave each boy as many jelly beans as there were boys in the class. She gave each girl as many jelly beans as there were girls in the class. She brought 400400 jelly beans, and when she finished, she had six jelly beans left. There were two more boys than girls in her class. How many students were in her class?

Pick one

Solution

If there are xx girls, then there are x+2x+2 boys. She gave each girl xx jellybeans and each boy x+2x+2 jellybeans, for a total of x2+(x+2)2x^2 + (x+2)^2 jellybeans. She gave away 4006=394400-6=394 jellybeans.
x2+(x+2)2=394x2+x2+4x+4=3942x2+4x=390x2+2x=195\begin{align*} x^2+(x+2)^2 &= 394\\ x^2+x^2+4x+4 &= 394\\ 2x^2 + 4x &= 390\\ x^2 + 2x &= 195\\ \end{align*}
From here, we can see that x=13x = 13 as 132+26=19513^2 + 26 = 195, so there are 1313 girls, 13+2=1513+2=15 boys, and 13+15=(B) 2813+15=\boxed{\textbf{(B)}\ 28} students.

Want a route through all this instead of an archive? The track puts 2,000 problems in a working order, from AMC 10 level to the IMO shortlist.

Source: NuminaMath-1.5, licensed Apache-2.0. Statement and solution reproduced as published; topic and difficulty added by this site.