So, let's say I'm rowing in a stream. If I row at 5 mph and the stream is flowing at 3 mph, I go 8 mph downstream and 2 mph upstream.
Upwind, the plane is travelling at 120 mph. Downwind, it's travelling at 180 mph.
d = rt, and the distance = 1800. The times are the same.
1800 = 180t + 120t
1800 = 300t
t = 6 hours each direction
180(6) = 1080 miles with the tailwind
120(6) or 1800 - 1080 = 720 miles into the headwind