Mara and Riley went to a carnival, Mara rode the bumper car two times, Riley rode the space shuttle four times, and they both rode the Ferris wheel three times. If a ticket for a bumper car cost $2, a ticket for a space shuttle cost $4, and a ticket for a Ferris wheel cost $5, how much money did they spend?
Mara spent $2 x 2 = $
<gadget id="calculator">2*2</gadget>
<output>4</output>
4 for riding the bumper car two times.
Riley spent $4 x 4 = $
<gadget id="calculator">4*4</gadget>
<output>16</output>
16 for riding the space shuttle 4 times.
They spent $5 x 3 = $
<gadget id="calculator">5*3</gadget>
<output>15</output>
15 each riding the Ferris wheel 3 times.
So, they spent a total of $15 x 2= $
<gadget id="calculator">15*2</gadget>
<output>30</output>
30 riding the Ferris wheel.
Therefore the total amount they spent at the carnival is $4 + $16 + $30 = $
<gadget id="calculator">4+16+30</gadget>
<output>50</output>
50.

<result>50</result>