#include <bits/stdc++.h>
using namespace std;
int main() {
  string S;
  cin >> S;
  string K = "keyence";
  int passed = 2;
  bool boolean = true;
  int s = 0, k = 0;
  while (true) {
    if (S[s] == K[k]) {
      if (passed == 2) passed--;
      s++;
      k++;
      if (k == K.length() and s == S.length()) break;
      if (k == K.length() and passed == 2) break;
    } else {
      s++;
      if (passed == 3)
        passed--;
      else if (passed == 1) {
        boolean = false;
        break;
      }
      if (s == S.length()) {
        boolean = false;
        break;
      }
    }
  }
  if (boolean) {
    cout << "YES" << endl;
  } else {
    cout << "NO" << endl;
  }
  return 0;
}
