#include <bits/stdc++.h>
using namespace std;
int main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  string s;
  cin >> s;
  int n = s.size();
  const string keyence = "keyence";
  int m = keyence.size();
  bool skiped = false;
  int j = 0;
  bool ans = true;
  for (int i = 0; i < m; ++i) {
    if (j < n && keyence[i] == s[j]) {
      ++j;
    } else if (!skiped) {
      skiped = true;
      while (j < n && keyence[i] != s[j]) ++j;
      if (j == n) {
        ans = false;
        break;
      }
      ++j;
    } else {
      ans = false;
      break;
    }
  }
  if (j != n) ans = false;
  if (ans)
    cout << "YES\n";
  else
    cout << "NO\n";
}
