# Problem of the Week Problem E Passing Trains

Two trains of equal length are on parallel tracks. One train travels at $$40$$ km/h and the other train travels at $$20$$ km/h.

One day, the two trains are travelling in the same direction, and the front end of the faster train is at the same place as the back end of the slower train. The faster train then completely passes the slower train so that the back end of the faster train is now at the same place as the front end of the slower train.

Another day, the two trains are travelling in opposite directions, and the front end of the faster train is at the same place as the front end of the slower train. The trains then completely pass each other so that the back end of the faster train is at the same place as the back end of the slower train.

If it takes $$2$$ minutes longer for the trains to completely pass one another when travelling in the same direction than it does when they are travelling in opposite directions, determine the length of each train.