#include <bits/stdc++.h>
using namespace std;
using ll = long long;
ll Max(ll(a), ll(b), ll(c)) { return max(max(a, b), c); }
ll Min(ll(a), ll(b), ll(c)) { return min(min(a, b), c); }
int main() {
  string S;
  cin >> S;
  for (long long i = 0; i < (long long)(8); i++) {
    string T = "";
    for (long long j = 0; j < (long long)(i); j++) {
      T += S.at(j);
    }
    for (long long j = 0; j < (long long)(7 - i); j++) {
      T += S.at(S.size() - (7 - i) + j);
    }
    cout << T << endl;
    if (T == "keyence") {
    }
  }
  cout << "NO" << endl;
}
