2009 AMC 8 Problem 23

Attempt Problem 23 of the 2009 AMC 8 below, then check your answer against the professionally curated solution from LIVE by Po-Shen Loh. You can also try the full timed exam, view all 2009 AMC 8 solutions, or check the answer key.

All problems are used with official legal permission of the Mathematical Association of America (MAA).

23.

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?
2626
2828
3030
3232
3434
Answer: B
Concepts:quadraticfactoring
Small hint:
Let the number of girls be g,g, so the number of boys is g+2.g+2.
Big hint:
The total jelly beans given out is 400−6.400-6.
Solution:
Let bb be the number of boys in the class and gg be the number of girls. From the problem, we get that b=g+2.b = g + 2.
If each boy gets bb jelly beans, then Mrs. Wonderful will give out a total of b2b^2 jelly beans to all the boys. Similarly, she will give out g2g^2 jelly beans to all the girls.
Therefore, b2+g2=400−6(g+2)2+g2=3942g2+4g+4=394g2+2g−195=0(g+15)(g−13)=0. \begin{gather*} b^2 + g^2 = 400 - 6 \\ (g + 2)^2 + g^2 = 394 \\ 2g^2 + 4g + 4 = 394 \\ g^2 + 2g - 195 = 0 \\ (g + 15)(g - 13) = 0. \end{gather*} Since gg cannot be negative, we get that g=13.g = 13. This means that b=15,b = 15, so b+g=28.b + g = 28.
Thus, B is the correct answer.
LIVE by Po-Shen Loh
Programs

LIVE Classes

Self-Paced Classes

Stars

Scholarship

About Us

Who Is Po-Shen Loh?

Email Contact

Newsletter

Jobs

Become a Star

For a more Thought Full world.

© 2026 Expii, Inc.