#include <bits/stdc++.h>
using namespace std;
int main() {
  bool flag = false;
  string s;
  cin >> s;
  string copy;
  copy = s;
  s += "wwww";
  for (int i = 0; i <= s.size(); i++) {
    for (int j = 1; i + j - 1 <= s.size(); j++) {
      s = copy;
      s.erase(i, j);
      if (s == "keyence") {
        flag = true;
        break;
      }
    }
    if (flag) break;
  }
  string ans = flag or copy == "keyence" ? "YES" : "NO";
  cout << ans << endl;
  return 0;
}
