#include <bits/stdc++.h>
using namespace std;
int main() {
  int cnt = 0, b[8] = {0}, i, t = 0;
  string s, a = "keyence";
  cin >> s;
  for (i = 0; i < s.size(); i++) {
    if (cnt >= 7) {
      break;
    }
    if (a[cnt] == s[i]) {
      if (t == 0)
        t = 1;
      else {
        if (t == 1) {
          t = 1;
        } else {
          if (t == 2) {
            t = 3;
          } else {
            if (t == 3) {
              t = 3;
            }
          }
        }
      }
      cnt++;
    } else {
      if (t == 1)
        t = 2;
      else {
        if (t == 2)
          t = 2;
        else {
          if (t == 3)
            t = 4;
          else {
            if (t == 4) t = 4;
          }
        }
      }
    }
    if (t == 4) break;
  }
  if (cnt == 7 && t < 4 && i == (s.size())) {
    cout << "YES" << endl;
  } else
    cout << "NO" << endl;
}
