Assume the speed of the train = x km/hour.
Distance = 480 km
Time taken = 480/x
ATQ
(480)/(x-8) - 480/x =3
480{(x-x+8) /x(x-8)} =3
480(8) =3x(x-8)
x2 - 8x -1280=0
x2 - 40x + 32x-1280=0
x(x-40) + 32 (x-40)=0
(x-40)(x+32)=0
x = -32 (not possible)
Hence x = 40 km/hour is the speed of the train.