Cars A and B are traveling towards each other at the same time from places A and B respectively. They met for the first time at a distance of 40 kilometers from point A, and then continued driving at the same speed. The two vehicles return immediately after arriving at places A and B, and meet for the second time at a distance of 20 kilometers from place B. How many kilometers are there between A and B?
甲、乙两车分别从A、B两地同时相向而行．在距A地40千米处第一次相遇，然后仍按原速继续行驶．两车各到达A、B两地后立即返回，在距B地20千米处第二次相遇．A、B两地相距多少千米？
<gadget id="calculator">40 * 3</gadget>
<output>120</output>

<gadget id="calculator">120 - 20</gadget>
<output>100</output>

<result>100</result>