fun main() {
    val (n, k) = readInts()
    val a = readInts()

    var rm = 0
    var curr = k
    while (curr < n) {
        if (a[curr] > a[rm]) println("Yes")
        else println("No")
        rm++
        curr++
    }
}

// Input Reader
private fun readLn() = readLine()!!

private fun readStrings() = readLn().trim().split(" ")
private fun readInts() = readStrings().map { it.toInt() }
