There are n coins on the table. Some of them have heads up, and some of them have tails up. Find the minimum number of coins to reverse, so that all coins will be turned up with the same side.
The first line contains number of coins n (1 ≤ n ≤ 100). Each of the next n lines contains one integer: 1 if the coin is tails up or 0 if heads up.
Print the minimum number of coins to reverse.
Input example #1
5 1 0 1 1 0
Output example #1