A train 300 m long overtook a man walking along the line in the same directionat the rate of 3km/hr and passed him in 36seconds find the speed of the train.

speed of train --- x km/h

so it took 36 to make up the 300 m at (x-3) km/h

36/60(x-3) = 300/1000
6/10(x-3) = 3/10
6(x-3) = 3
6x - 18 = 3
6x = 21
x = 3.5 km/h

check:
in 36 seconds, train went
(36/60)(3.5) km = 2.1 km or 2100 m
in the meantime the man went
(36/60)(3) km = 1.8 km or 1800 m
the difference being 300 m,