Step-by-step explanation:
the mass of 4000kg is just mentioned to confuse us. it has nothing to do with the solution of the question.
speed is distance/time, which is independent from any mass involved. and the question about the needed time is also independent from mass (but mass would be a factor, if the question were about e.g. the force of an impact of that train with a solid object).
so, any object of any mass, as it travels at 3m/s needs the same amount of time to move 180m.
it needs as many seconds as the number of times 3m fit into 180m, because
3m/s × x seconds = 180m
3m × x = 180m
x = 180m/3m = 60
so, it takes the train 60 seconds (= 1 minute) to move 180 meters when going 3m/s.