#include <bits/stdc++.h>
using namespace std;
long long min(long long x, long long y) { return (x < y ? x : y); }
long long max(long long x, long long y) { return (x > y ? x : y); }
int stoi(string s) { return atoi(s.c_str()); }
int keta(long long x) {
  if (x < 10) {
    return 1;
  } else {
    return keta(x / 10) + 1;
  }
}
int main() {
  string s;
  cin >> s;
  int s_size = s.size();
  string k = "keyence";
  int k_point = 0;
  int k_size = k.size();
  char c;
  char d = k[k_point];
  bool eliminating = false;
  bool cannot = false;
  bool r = true;
  for (int i = 0, i_len = (s_size); i < i_len; ++i) {
    c = s[i];
    if (c == d) {
      k_point++;
      d = k[k_point];
      if (eliminating) {
        eliminating = false;
        cannot = true;
      }
    } else {
      if (!eliminating) {
        eliminating = true;
      }
      if (cannot) {
        r = false;
        break;
      }
    }
  }
  if (k_point != k_size) {
    r = false;
  }
  cout << (r ? "YES\n" : "NO\n");
}
