A train covered a certain distance at a uniform speed

A train covered a certain distance at a uniform speed. If the train would have been 10km/h faster, it would have taken 2 hours less than the schedule time. And, if the trains were slower by 10km/hr, it would have taken 3 hours more than the scheduled time. Find the distance covered by the train.

Let the original speed of train be x km/hr and the schedule time of journey be y hours.
Therefore, s = d/t
i.e. d = xykm.
If speed of the train increases by 10km/hr, then increased speed = (x + 10)km/hr
Time reduces by 2hrs, so reduced time = (y - 2)h
Therefore,
Distance = (x + 10)(y-2) = xy -2x + 10y - 20
In both the cases distances are equal
xy = xy - 2x + 10y - 20
⇒ x - 5y = -10
⇒ x = 5y -10 ----- (1)
If speed is reduced by 10km/hr, then the reduced speed = (x - 10)km/h
If time is increased by 3hr, then the increased time = (y + 3)hr
Then, distance = (x - 10)(y + 3) = xy + 3x - 10y - 30
∴ xy = xy + 3x - 10y - 30
⇒ 3x - 10y = 30 ----- (2)
Using substitution method, subs. (1) in (2), we have
⇒ 3(5y - 10) - 10y = 30
⇒ 15y - 30 - 10y = 30
⇒ 5y = 60
⇒ y = 12
Subs. value of y in (1)
x = 5(12) - 10 = 50
x = 50
Therefore, distance = xy = 50 x 12 = 600km
Hence, distance covered by the train is 600km.