#include <bits/stdc++.h>
using namespace std;
int main() {
  string S;
  string K = "keyence";
  cin >> S;
  int i = 0, j = 0;
  while (i < S.size()) {
    if (S[i++] != K[j++]) {
      j--;
      break;
    }
  }
  int x = S.size() - 1, y = K.size() - 1;
  while (j < y) {
    if (S[x--] != K[y--]) {
      y++;
      break;
    }
  }
  if (abs(y - j) <= 1) {
    cout << "YES" << endl;
  } else {
    cout << "NO" << endl;
  }
  return 0;
}
