Silly monkey has a very small vocabulary, so every time he does English multiple-choice questions, he has a headache. But he found a method, and it has been proved by experiments that when using this method to choose options, the chance of choosing the right one is very high!
The specific description of this method is as follows: Suppose is the number of occurrences of the letter that appears the most frequently in the word, and is the number of occurrences of the letter that appears the least frequently in the word. If is a prime number, then silly monkey thinks this is a Lucky Word
, such a word is likely to be the correct answer.
Input Specification
There is only one line, which is a word consisting of only lower characters (a
- z
), and the length is at most .
Output Specification
Two lines in total, the first line is a string, if the input word is Lucky Word, then output Lucky Word
, otherwise output No Answer
.
The second line is an integer, if the input word is Lucky Word
, output the value of , otherwise output 0
.
Sample Input 1
error
Sample Output 1
Lucky Word
2
#Explanation of Sample Outpt 1
The letter r
that appears the most in the word error appears 3 times, and the letter that appears the least frequently appears once, , and 2 is a prime number.
Sample Input 2
olympic
Sample Output 2
No Answer
0
Explanation of Sample Output 2
The letter that appears the most in the word olympic appears 1 time, and the letter that appears the least frequently appears 1 time, , 0 is not a prime number.
Comments