Mary buys 3 bags of M&Ms. The first bag has 300 M&Ms in it. The second bag has 12 more M&Ms than the first, and the third bag has a hole in it, so it only has half the number of M&Ms that the first bag had. How many M&Ms did Mary get total?
First Bag:300.
Second Bag:300+12=
<gadget id="calculator">300+12</gadget>
<output>312</output>
312.
Third Bag:300/2=
<gadget id="calculator">300/2</gadget>
<output>150</output>
150.
Total number of M&amp;M's: 300+312+150=
<gadget id="calculator">300+312+150</gadget>
<output>762</output>
762 M&amp;M's.

<result>762</result>