#include <bits/stdc++.h>
using namespace std;
int main() {
  string s, t = "keyence";
  cin >> s;
  int j = 0;
  bool f = false, ff = false;
  for (int i = 0; i < s.size(); i++) {
    if (j == 8) {
      if (f) {
        cout << "NO";
        return 0;
      } else {
        break;
      }
    }
    if (s[i] == t[j]) {
      if (f) ff = true;
      j++;
    } else {
      if (!ff) {
        f = true;
      } else {
        cout << "NO";
        return 0;
      }
    }
  }
  cout << (j == 8 ? "YES" : "NO");
}
