#include <bits/stdc++.h>
using namespace std;
using ll = long long;
using ld = long double;
const int MOD = 1e9 + 7;
int main() {
  string s;
  cin >> s;
  for (int i = 0; i < (int)s.size() - 6; i++) {
    if (s.substr(i, 3) == "key") {
      for (int j = i + 3; j < (int)s.size() - 3; j++) {
        if (s[j] != 'e') continue;
        if (s.substr(j, 4) == "ence") {
          cout << "YES" << endl;
          return 0;
        }
      }
    }
  }
  cout << "NO" << endl;
  return 0;
}
