fun main(args: Array<String>) {
    val strings = readLine()!!
    val keyence = "keyence"
    val length = strings.length
    if (length < 7) {
        print("NO")
    } else {
        var firstCount = 0
        var secondCount = 0
        val charKeyence = keyence.toCharArray()
        run loop@{
            strings.subSequence(0, 7).forEach {
                if (it == charKeyence[firstCount]) {
                    firstCount++
                } else {
                    return@loop
                }
            }
        }
        run loop@{
            strings.subSequence(length - 7, length).reversed().forEach {
                if (it == charKeyence[7 - secondCount - 1]) {
                    secondCount++
                } else {
                    return@loop
                }
            }
        }
        if (firstCount + secondCount >= 7) {
            print("YES")
        } else {
            print("NO")
        }
    }
}