#include <bits/stdc++.h>
using namespace std;
int main() {
  string S;
  cin >> S;
  string key = "keyence";
  int j = 0;
  string sub = "";
  for (int i = 0; i < S.size(); i++) {
    if (j == 7) {
      sub.insert(sub.end(), S.begin() + i, S.end());
      break;
    }
    if (S.at(i) == key.at(j)) {
      j++;
    } else {
      sub += S.at(i);
    }
  }
  if (j != 7) {
    cout << "NO" << endl;
    return 0;
  }
  if (sub.size() == 0) {
    cout << "YES" << endl;
    return 0;
  }
  for (int i = 0; i < S.size(); i++) {
    if (S.substr(i, sub.size()) == sub) {
      cout << "YES" << endl;
      return 0;
    }
  }
  cout << "NO" << endl;
  return 0;
}
