Here, distance travelled by the bus in `5` minutes will be equal to the sum of the distance covered by the bus and the man in `4` minutes.
Let speed of the man is `x` km/h.
Then,
`40**5/60 = 40**4/60+x**4/60`
`=>10/3 = 8/3+x/15`
`=>2/3 = x/15`
`=>x = 10`
So, the speed of the man is `10` km/h.