#Lutece2706. Little Rabbit Numbers

Little Rabbit Numbers

Migrated from Lutece 2706 Little Rabbit Numbers

All parts of this problem, including description, images, samples, data and checker, might be broken. If you find bugs in this problem, please contact the admins.

Description

A Fermat number is a positive integer of the form

Fn=22n+1F_n=2^{2^n}+1

where nn is a non-negative integer. The first few Fermat numbers are:

F0F_0 F1F_1 F2F_2 F3F_3 F4F_4 \cdots
33 55 1717 257257 6553765537 \cdots

Fermat numbers were first studied by Pierre de Fermat, who conjectured that all Fermat numbers are prime in 1640. As we know, the prime numbers are the natural numbers greater than 11 that have no divisors but 11 and themselves. Indeed, the first five Fermat numbers F0,F1,F2,F3,F4F_0, F_1, F_2, F_3, F_4 are easily shown to be prime. But in 1732, Leonhard Euler refuted Fermat's conjecture, since he showed that F5=4294967297=641×6700417F_5=4294967297=641\times6700417. Although Fermat's conjecture is not correct, the primality of Fermat numbers is still a topic worth studying.

Little Rabbit, who has a great interest in math, conducts an in-depth study of Fermat numbers. After that, he creates Little Rabbit numbers, which is a positive integer of the form

Ln=Fn+f(Fn)2L_n=\left\lfloor\dfrac{F_n+f(F_n)}{2}\right\rfloor

where FnF_n is the Fermat number. The function f(x)f(x) means the largest prime which is strictly less than xx. For example, f(3)=2f(3)=2, and f(4)=f(5)=3f(4)=f(5)=3. And we use x\lfloor x \rfloor to indicate the largest integer that does not exceed xx.

Little Rabbit is curious about the primality of Little Rabbit numbers. Now given nn, can you tell him whether LnL_n is prime?

Input

An integer nn (0n1000 \le n \le 100).

Output

If LnL_n is prime, output YES\texttt{YES}. Otherwise, output NO\texttt{NO}.

Samples

0
YES
1
NO

Note

For the first example, $L_0=\left\lfloor\dfrac{F_0+f(F_0)}{2}\right\rfloor=\left\lfloor\dfrac{3+2}{2}\right\rfloor=2$ is a prime number.

For the second example, $L_1=\left\lfloor\dfrac{F_1+f(F_1)}{2}\right\rfloor=\left\lfloor\dfrac{5+3}{2}\right\rfloor=4$ is not a prime number.

Resources

电子科技大学第十二届 ACM 趣味程序设计竞赛