AmazonOA #196
Get Exp.
估计简单可在线判题
Repeatedly take the two people with the highest and the lowest remaining experience, pair them and remove them; count the distinct values among the pairs' average experience. People with the same experience are still separate individuals.
输入格式
The first line contains an even n; the second line contains n experience values. 2≤n≤100000, 0≤experience≤10^9.
输出格式
Output a single integer, the answer.
样例 1
输入:
6
1 4 1 3 5 6
输出:
2
样例 2
输入:
2
0 0
输出:
1
样例 3
输入:
4
1 100 10 1000
输出:
2
样例说明
The answers are 2, 1 and 2; the sums in the first example are 7, 6 and 7.