Hide

Problem C
Primality

Given a positive integer N, determine whether it is prime or not.

Input

The first line contains the integer N (2N1018).

Output

Output YES if N is prime, and NO otherwise.

Scoring

Your solution will be tested on a set of test groups, each worth a number of points. To get the points for a test group you need to solve all test cases in the test group.

Group

Points

Constraints

1

1

N1016

2

1

No additional constraints

Sample Input 1 Sample Output 1
6
NO
Sample Input 2 Sample Output 2
7
YES
Hide

Please log in to submit a solution to this problem

Log in