Two ships, A and B, depart from ports A and B at the same time and travel towards each other. They can meet each other in 8 hours. From port A to port B, it takes 12 hours for ship A to travel from port B to port A. How many hours does it take for ship B to travel from port B to port A?
甲、乙两船分别从A、B两个港口同时出发相向而行，8小时可以相遇，从A港口到B港口，甲船需要12小时，乙船从B港口到A港口需要多少小时？
<gadget id="calculator">1 / 8</gadget>
<output>1/8 = around 0.125</output>

<gadget id="calculator">1 / 12</gadget>
<output>1/12 = around 0.083333</output>

<gadget id="calculator">(1/8) - (1/12)</gadget>
<output>1/24 = around 0.041667</output>

<gadget id="calculator">1 / (1/24)</gadget>
<output>24</output>

<result>24</result>