#include <bits/stdc++.h>
using namespace std;
int main() {
  string x = "keyence";
  string s;
  cin >> s;
  for (int i = 0; i < 7; i++) {
    if (s.find(x.substr(0, i)) != -1 &&
        s.rfind(x.substr(i, x.size() - 1)) != -1 &&
        s.find(x.substr(0, i)) < s.rfind(x.substr(i, x.size() - 1))) {
      cout << "YES" << endl;
      return 0;
    }
  }
  cout << "NO" << endl;
  return 0;
}
