Well, first remember "Distance Is Rate times Time" (a.k.a., D-I-R-T, you know, dirt)
In this problem, we don't need to find the distance, but we know that going "to" is the same distance as coming "from".
Let X = speed of return trip (the value we want to find)
Coming from: D = X mi/hr * 7 hrs
Going to: D = (X -18) mi/hr * 10 hr (18 mph slower)
D = X*7 = (X-18)*10 (first D = second D)
7X = 10X - 180
-3X = -180
X = 60 mph
Is 60*7 = (42)*10 ? Yes.