#include <bits/stdc++.h>
using namespace std;
int main() {
  string s;
  cin >> s;
  int keyence_i = 0;
  string keyence_s = "keyence";
  string creating = "";
  int deleted_i = -1;
  for (int i = 0; i < s.size(); ++i) {
    if (keyence_s[keyence_i] == s[i]) {
      creating += s[i];
      keyence_i++;
    } else {
      if (deleted_i != -1 && deleted_i + 1 != i) {
        cout << "NO" << endl;
        return 0;
      };
      deleted_i = i;
    }
  }
  if (creating == keyence_s)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
  return 0;
}
