defmodule Main do
  def main do
    [n, k] =
      IO.read(:line) |> String.trim() |> String.split(" ") |> Enum.map(&String.to_integer/1)

    IO.read(:line)
    |> String.trim()
    |> String.split(" ")
    |> Enum.map(&String.to_integer/1)
    |> solve(n, k)
  end

  def solve(list, n, k) do
    map = list |> Enum.with_index() |> Enum.map(fn {a, b} -> {b, a} end) |> Map.new()

    k..(n - 1)
    |> Enum.each(fn i ->
      if(Map.get(map, i) > Map.get(map, i - k), do: "Yes", else: "No")
      |> IO.puts()
    end)
  end
end