| 시간 제한 | 메모리 제한 | 제출 | 정답 | 맞힌 사람 | 정답 비율 |
|---|---|---|---|---|---|
| 1 초 (추가 시간 없음) | 1024 MB | 75 | 39 | 37 | 69.811% |
The Intense Challenges Players Club (ICPC) is hosting a DiviDuelo tournament.
DiviDuelo is a new two-player, turn-based game. In DiviDuelo, a number $N$ is selected and the list of its divisors is written. For example, if $N = 10$ is selected, the list of numbers 1ドル,ドル 2ドル,ドル 5ドル,ドル 10ドル$ is written. Players alternate turns picking one still unpicked divisor from the list each turn, until all divisors have been picked.
The winner is determined by the greatest common divisor (GCD) of the numbers picked by the starting player. If the GCD is not equal to 1ドル,ドル the starting player wins. Otherwise, if the GCD is equal to 1ドル,ドル the other player wins.
The ICPC needs your help to prepare some statistics about the games played in the tournament. Given the value of $N,ドル determine if the starting player can win the game assuming both players play optimally.
The input consists of a single line that contains an integer $N$ (1ドル ≤ N ≤ 10^{12}$) indicating the number selected for the game.
Output a single line with the uppercase letter “Y” if the starting player can win the game and the uppercase letter “N” otherwise, assuming both players play optimally.
10
Y
9
N
1
N