#include <bits/stdc++.h>
using namespace std;
const int MAX = 999999999;
int main() {
  string s;
  cin >> s;
  bool flag = false;
  string keyence = "keyence";
  for (int i = 0; i < s.size(); i++) {
    for (int j = 1; j < s.size() - i; j++) {
      int cnt = 0;
      for (int k = 0; k < s.size(); k++) {
        if ((k < i || i + j < k) && s[k] == keyence[cnt]) cnt++;
      }
      if (cnt == 7) flag = true;
    }
  }
  if (flag)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
}
