#include <bits/stdc++.h>
using namespace std;
using pii = pair<int, int>;
int main() {
  ios_base::sync_with_stdio(false);
  cin.tie(nullptr);
  cout.tie(nullptr);
  string s1 = "keyence", s2;
  cin >> s2;
  bool skipped = false;
  int i, j = 0;
  for (i = 0; i < s1.size() && j < s2.size(); i++) {
    if (s1[i] != s2[j]) {
      if (skipped) {
        cout << "NO\n";
        return 0;
      }
      skipped = true;
      while (s1[i] != s2[j] && j < s2.size()) j++;
      i--;
    } else {
      j++;
    }
  }
  if (i != s1.size() || j != s2.size()) {
    cout << "NO\n";
  } else {
    cout << "YES\n";
  }
  return 0;
}
