Thomas withdraws $1000 in 20 dollar bills from the bank account.  He loses 10 bills while getting home.  After that, he uses half of the remaining bills to pay for a bill.  Thomas then triples his money.  He then converts all his bills to 5 dollar bills.  How many 5 dollar bills does he have?
He withdrew 1000/20=
<gadget id="calculator">1000/20</gadget>
<output>50</output>
50 bills.
So he has 50-10=
<gadget id="calculator">50-10</gadget>
<output>40</output>
40 bills left over.
He uses half the bills to pay for something, so he has 40/2=
<gadget id="calculator">40/2</gadget>
<output>20</output>
20 bills.
He triples his money which gives him 20*3=
<gadget id="calculator">20*3</gadget>
<output>60</output>
60 bills.
So he has 60*20=$
<gadget id="calculator">60*20</gadget>
<output>1_200</output>
1200.
Converting to 5s means he has 1200/5=
<gadget id="calculator">1200/5</gadget>
<output>240</output>
240 bills.

<result>240</result>