I will assume for this problem that the San Francisco - NY journey encounters the same wind but in the opposite(positive) direction.
for this problem the distance traveled is the same so you must find two equations and set them equal to the other. For the purposes of this problem x will be the speed the plane flies(with no wind). Y will be the wind.
6(x - y) = 5(x + y) = 4200
6x - 6y = 5x + 5y
For this problem you can take one of the equations in terms of the 4200 and substitute but the easiest way is to multiply one of the equations so that you can add the linear equations and isolate a variable.
5x + 5y = 4200 multiplied by 6/5 is 6x + 6y = 5040
6x + 6y = 5040
6x - 6y = 4200
+
————————
12x = 9240
x = 770
plug in x to one of the equations and you find y = 70