Darcy is celebrating his IOI platinum medal. At his party, he tried to split up his cake into many slices and distributed the slices equally. However, his supervisor Eric noticed that Darcy accidentally gave some people an incorrect amount of slices. Calculate how many times Darcy made a mistake.
Real problem statement:
Darcy is celebrating after winning the IOI platinum medal. At his party, Darcy made some cake and split it equally among the guests, giving everyone an equal amount. Everybody there either enjoyed it or didn't enjoy it (you can't do both). What they didn't know was that Darcy was secretly hired by Eric to spy on potential enemies. During the party, Darcy began to notice something strange: those who enjoyed cake were beginning to BUY cake from those who didn't! Such a display shall not fool Darcy, for he has taken economics and knows this is an unacceptable instance of the free market. Help Darcy find out how many people have participated in this illegal activity.
Input Specification
The first line contains
, the number of people at the party.
The next line contains
integers, each integer
representing the number of slices of cake the
person has.
It is guaranteed that the total number of slices will be divisible by the number of people at the party.
Output Specification
Output the number of people who did not receive the number of slices they should have received if the cake was divided equally.
Constraints

Sample Input
Copy
5
1 3 2 2 2
Sample Output
Copy
2
Explanation
If the slices were evenly distributed, everyone would receive 2 slices. Darcy only gave 1 slice to person 1, and gave the extra slice to person 2.
Comments