#include <bits/stdc++.h>
using namespace std;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(NULL);
  string str;
  cin >> str;
  int n = str.size();
  string temp = "keyence";
  int l = 0, r = n - 1;
  while (l < 7 && str[l++] == temp[l - 1]) {
  }
  if (l != 7) {
    l -= 2;
    int j = 6;
    while (j >= 0 && str[r--] == temp[j--]) {
      if (j + 1 == l) {
        break;
      }
    }
    if (j == -1) {
      cout << "YES" << '\n';
      return 0;
    }
    j++;
    if (j != 0 && (l != j)) {
      cout << "NO" << '\n';
      return 0;
    } else {
      cout << "YES" << '\n';
    }
  } else {
    cout << "YES" << '\n';
  }
  return 0;
}
