题目描述
Problem Description
Twin sisters Yes and No are participating in a programming contest in Tokyo. To warm up, they decided to play a game on the Shinkansen (bullet train) heading to the venue.
The sisters write $ N $ positive integers on a piece of paper. The $i\ (1\ \leq\ i\ \leq\ N)$ -th value is $ A_i $.
In the game, Yes goes first, and No goes second, alternating turns performing the following operation:
- Choose one of the integers on the paper that is greater than or equal to $ 2 $ and replace it with a smaller positive divisor.
The person who cannot make an operation first loses.
When both play optimally, who will win, Yes or No?
Input Format
The input is given from the standard input in the following format:
$ N $ $ A_1 $ $ A_2 $ $\dots$ $ A_N $
Output Format
Output Yes if Yes wins when both play optimally, or No if No wins.
Sample Input and Output
Sample Input #1
5
1 2 3 4 5
Sample Output #1
Yes
Sample Input #2
6
1 1 1 1 1 1
Sample Output #2
No
Sample Input #3
3
19 12 15
Sample Output #3
No
Sample Input #4
10
91 92 93 94 95 96 97 98 99 100
Sample Output #4
No
Notes/Hints
Constraints
- All inputs are integers.
- $1\ \leq\ N\ \leq\ 100$
- $1\ \leq\ A_i\ \leq\ 100\ (1\ \leq\ i\ \leq\ N)$
Sample Explanation 1
An example of the game progression is as follows:
- Yes changes $ A_4 $ from $ 4 $ to $ 2 $.
- No changes $ A_3 $ from $ 3 $ to $ 1 $.
- Yes changes $ A_2 $ from $ 2 $ to $ 1 $.
- No changes $ A_4 $ from $ 2 $ to $ 1 $.
- Yes changes $ A_5 $ from $ 5 $ to $ 1 $.
- No cannot make any more moves, so Yes wins.
No matter how No moves, Yes can always make appropriate moves to force No to be unable to move first.
Sample Explanation 2
Since no moves can be made from the start, No wins.
输入格式
见题面 Input 部分
输出格式
见题面 Output 部分