#include <bits/stdc++.h>
const std::string kKeyence = "keyence";
bool check(const std::string& input, size_t idx, size_t next_keyence_idx,
           bool has_skipped) {
  if (next_keyence_idx == kKeyence.size()) return true;
  if (input.size() == idx) return false;
  if (input[idx] == kKeyence[next_keyence_idx]) {
    bool ret = check(input, idx + 1, next_keyence_idx + 1, has_skipped);
    if (ret) return true;
  }
  if (!has_skipped) {
    for (size_t i = idx + 1; i < input.size(); i++) {
      bool ret = check(input, i, next_keyence_idx, true);
      if (ret) return true;
    }
  }
  return false;
}
int main() {
  std::string input;
  std::cin >> input;
  std::cout << ((check(input, 0, 0, false)) ? "YES" : "NO") << std::endl;
  return 0;
}
