Master Wang buys gasoline and puts it in barrels A and B, both of which are not full. If barrel A is poured into barrel B, after barrel B is full, there will be 10 liters left in barrel A; Pour everything into barrel A, and barrel A can hold another 20 liters. It is known that the capacity of barrel A is 2.5 times that of barrel B. How many liters of gasoline did Mr. Wang buy in total?
王师傅买汽油装在甲、乙两个桶里，两个桶均未装满，如果将甲桶汽油倒入乙桶，乙桶装满后，甲桶还剩10升；如果将乙桶汽油全部倒入甲桶，甲桶还能再装20升，已知甲桶容量是乙桶的2.5倍，求王师傅一共买了多少升汽油？
<gadget id="calculator">10 + 20</gadget>
<output>30</output>

<gadget id="calculator">2.5 - 1</gadget>
<output>1.5</output>

<gadget id="calculator">30 / 1.5</gadget>
<output>20</output>

<gadget id="calculator">20 + 10</gadget>
<output>30</output>

<result>30</result>