Ali has $480. He spent half of it on food, and then he spent a third of what was left on a pair of glasses. How much money did he have left?
Ali spent 480/2=$
<gadget id="calculator">480/2</gadget>
<output>240</output>
240 on food.
After buying the food, Ali had 480-240=$
<gadget id="calculator">480-240</gadget>
<output>240</output>
240 left.
He spent 240/3=
<gadget id="calculator">240/3</gadget>
<output>80</output>
80 dollars on a pair of glasses.
He had 240-80=$
<gadget id="calculator">240-80</gadget>
<output>160</output>
160 left.

<result>160</result>