#include<iostream>
#include<string>
#include<cstring>
using namespace std;
const int inf = 1e8;
const int maxn = 26 + 10;
int small[maxn];
bool isPrime(int x){
if(x == 1) return false;
for(int i = 2; i * i <= x; i++){
if(x % i == 0) return false;
}
return true;
}
int main(){
string s; cin >> s;
int mx = -inf, mi = inf;
int len = s.length();
for(int i = 0; i < len; i++) small[s[i] - 'a']++;
for(int i = 0; i < 25; i++){
mx = max(mx, small[i]);
mi = min(mi, small[i]);
}
mi = max(mi, 1);
int k = mx - mi;
if(isPrime(k)){
cout << "Lucky Word\n";
cout << k << "\n";
} else{
cout << "NO Answer\n0\n";
}
return 0;
}