A and B each brought some money to buy books. A spent 18 yuan to buy books, and B spent 24 yuan to buy books. At this time, the ratio of the total amount left by the two to the original total amount is 4:7. How much did the two bring together?
甲、乙两人各带了一些钱去买书，甲买书用去18元，乙买书用去24元，这时两人剩下的总数与原来总钱数的比是4：7，问：原来两人共带了多少钱？
<gadget id="calculator">18 + 24</gadget>
<output>42</output>

<gadget id="calculator">4 / 7</gadget>
<output>4/7 = around 0.571429</output>

<gadget id="calculator">1 - (4/7)</gadget>
<output>3/7 = around 0.428571</output>

<gadget id="calculator">42 / (3/7)</gadget>
<output>98</output>

<result>98</result>