#include <bits/stdc++.h>
using namespace std;
int main() {
  string s, key = "keyence";
  cin >> s;
  bool bef = false;
  int cnt = 0, now = 0;
  for (int i = 0; i < (int)(s.size()); i++) {
    if (now == 7) {
      cnt++;
      break;
    }
    if (s[i] == key[now]) {
      now++;
      bef = true;
    } else {
      if (bef) {
        bef = false;
        cnt++;
      }
    }
  }
  if (cnt >= 2 || now != 7) {
    cout << "NO" << endl;
  } else
    cout << "YES" << endl;
  return 0;
}
