Pairs

Time Limit: 2000ms
Memory Limit: 32768KB
This problem will be judged on HDU. Original ID: 2942
64-bit integer IO format: %I64d      Java class name: Main

Description

Given n positive integers, is it possible to divide them into pairs so that the sum of each pair is the same?

Input

The input contains several test cases. The first line of each case contains a single integer n (2 ≤ n ≤ 100). The second line contains n positive integers not greater than 1000. These numbers are sorted in non-decreasing order. The last case is followed by a single zero, which should not be processed.

Output

For each case, output ‘Yes’ or ‘No’ depending on whether or not the pairing is possible.

Sample Input

4
1 3 4 6
3
1 1 1
0

Sample Output

Yes
No

Source

Language: 
Theme: 
Share Code? 

Powered by NB231 | Current Style: .