#include <bits/stdc++.h>
using namespace std;
using ll = long long;
int main() {
  string S;
  cin >> S;
  string keyence = "keyence";
  string left = "";
  string right = "";
  bool flag = false;
  for (int i = 0; i < S.size(); ++i) {
    if (S[i] != keyence[i]) break;
    left = left + S[i];
  }
  for (int i = 0; i < S.size(); ++i) {
    if (S[S.size() - i - 1] != keyence[keyence.size() - i - 1]) break;
    right = S[S.size() - i - 1] + right;
  }
  if (left == keyence || right == keyence || left + right == keyence)
    cout << "YES" << endl;
  else
    cout << "NO" << endl;
  return 0;
}
