#abc200d. [abc200_d]Happy Birthday! 2
[abc200_d]Happy Birthday! 2
Problem Statement
You are given a sequence of positive integers: . Determine whether there is a pair of sequences $B = (B_1, B_2, \\dots, B_x), C = (C_1, C_2, \\dots, C_y)$ satisfying all of the conditions, and print one such pair if it exists.
- .
- .
- .
- and are different sequences.
- Here, we consider and different when or there is an integer such that .
- and are equal modulo .
Constraints
- All values in input are integers.
Input
Input is given from Standard Input in the following format:
Output
If there is no pair of sequences satisfying the conditions, print a single line containing No
.
Otherwise, print your choice of and in the following format:
Yes
The checker is case-insensitive: you can use either uppercase or lowercase letters.
Sample Input 1
5
180 186 189 191 218
Sample Output 1
Yes
1 1
2 3 4
For , we have , which are equal modulo .
There are other solutions that will also be accepted, such as:
yEs
4 2 3 4 5
3 1 2 5
Sample Input 2
2
123 523
Sample Output 2
Yes
1 1
1 2
Sample Input 3
6
2013 1012 2765 2021 508 6971
Sample Output 3
No
If there is no pair of sequences satisfying the conditions, print a single line containing No
.