There are 400 more men than women at a funfair in the morning. In the afternoon 2/5 of the men and 1/4 of the women left the funfair. As a result, there were 120 more men than women remaining at the funfair. How many men were there at the funfair at first