#include <bits/stdc++.h>
const int INF = 1e9;
const int MOD = 1e9 + 7;
using LL = long long;
const LL LINF = 1e18;
const double EPS = 1e-10;
using namespace std;
class PalseError {};
class Edge {
 public:
  int from, to, value;
  Edge(LL a, LL b, LL c) {
    from = a;
    to = b;
    value = c;
  }
  Edge(LL a, LL b) {
    from = a;
    to = b;
  }
};
int main() {
  string str;
  cin >> str;
  int N = str.size();
  cout << ((str.substr(0, 3) == "key" && str.substr(N - 4, 4) == "ence") ? "YES"
                                                                         : "NO")
       << endl;
  return 0;
}
