Let x = distance from Hughesville to Rockville
Distance = (Rate)(Time), so Time = Distance/Rate
Time of passenger train = Time of freight train - 5
x/76 = x/38 - 5
Multiply both sides by the LCD, 76:
x = 2x - 380
-x = - 380 So, x = 380 miles