#include <bits/stdc++.h>
#pragma GCC optimize("Ofast")
#pragma GCC optimize("unroll-loops")
#pragma GCC target("sse2")
using namespace std;
int32_t main() {
  ios::sync_with_stdio(0);
  cin.tie(0);
  cout.tie(0);
  ;
  string s;
  cin >> s;
  string t = "keyence";
  long long n = s.length();
  long long m = t.length();
  if (n < m) {
    cout << "NO";
    return 0;
  }
  long long i = 0;
  long long j = 0;
  long long d = m - 1;
  for (; i < n; i++) {
    if (j == m) break;
    if (s[i] == t[j]) {
      j++;
    } else
      break;
  }
  long long u = i;
  for (i = n - 1; i >= u and d >= j and j != m - 1; i--) {
    if (s[i] == t[d]) {
      d--;
    } else
      break;
  }
  if (j == m - 1 or d == 0 or d < j)
    cout << "YES";
  else
    cout << "NO";
  return 0;
}
