#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main(int argc, const char* argv[]) {
  string s, S = "keyence";
  cin >> s;
  int idx = 0;
  bool change = false;
  bool pre_change = false;
  int num = -1;
  string ans = "";
  for (int i = 0; i < s.length(); i++) {
    if (s[i] == S[idx]) {
      ans += s[i];
      idx++;
      pre_change = false;
    } else if (s[i] != S[idx] && (!change || pre_change)) {
      change = true;
      pre_change = true;
      if (change && !pre_change) {
        break;
      }
    } else {
      break;
    }
    num = i;
  }
  if (ans == S && num == s.length()) {
    cout << "YES" << endl;
  } else {
    cout << "NO" << endl;
  }
}
