The fast train and the slow train respectively depart from places A and B at the same time. When the slow train travels 1/2 of the whole journey, the ratio of the distance traveled by the express train to the remaining distance is 3:2. The distance between the cars is 40 kilometers, find the distance between A and B.
快、慢两车分别从甲、乙两地同时相对开出，当慢车行了全程的(1/2)时，快车所行路程和剩下的路程的比是3：2，这时两车相距40千米，求甲乙两地的距离．
<gadget id="calculator">1 / 2</gadget>
<output>1/2 = around 0.5</output>

<gadget id="calculator">3 + 2</gadget>
<output>5</output>

<gadget id="calculator">3 / 5</gadget>
<output>3/5 = around 0.6</output>

<gadget id="calculator">(3/5) - 1</gadget>
<output>-2/5 = around -0.4</output>

<gadget id="calculator">(1/2) + (-2/5)</gadget>
<output>1/10 = around 0.1</output>

<gadget id="calculator">40 / (1/10)</gadget>
<output>400</output>

<result>400</result>