#include <bits/stdc++.h>
using namespace std;
const long long MOD = 1e9 + 7;
const long long INF = 1e18;
signed main() {
  cin.tie(nullptr);
  ios::sync_with_stdio(false);
  string s, t = "keyence";
  cin >> s;
  long long b = 0, l = s.length() - 1;
  while (s[b] == t[b] && b < l) {
    b++;
  }
  long long k = 6;
  while (s[l] == t[k] && b + 1 < k) {
    l--;
    k--;
  }
  if (k - b == 1 || b == 7 || l == s.length() - 7) {
    cout << "YES" << endl;
  } else {
    cout << "NO" << endl;
  }
}
