#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(false);
  cin.tie(nullptr);
  string s;
  cin >> s;
  int n = s.size();
  string key = "keyence";
  string sub1 = "";
  string sub2 = "";
  bool flag1 = true;
  for (int i = 0; i < key.size(); i++) {
    if (s[i] == key[i])
      sub1 += s[i];
    else
      break;
  }
  for (int i = 0; i < key.size(); i++) {
    if (s[n - 1 - i] == key[key.size() - 1 - i])
      sub2 += s[n - 1 - i];
    else
      break;
  }
  reverse(sub2.begin(), sub2.end());
  sub2 = sub1 + sub2;
  if (sub1 == key || sub2 == key) {
    cout << "YES" << '\n';
  } else {
    cout << "NO" << '\n';
  }
  return 0;
}
