using System;
using System.Linq;
using System.Collections.Generic;

namespace cs
{
    class Program
    {
        static void Main(string[] args)
        {
            var pg = new Program();
            //pg.Test();
            pg.Execute();

        }
        private void Test()
        {
        }

        private void Execute()
        {
            var (N, K) = ReadLinesTuple2<int>();
            var input = ReadLinesList<long>().ToList();

            for (int i = K; i < N ; i++)
            {
                Output(input[i] > input[i - K] ? "Yes" : "No");
            }
        }


        private void Output<T>(T result) => Console.WriteLine(result);

        private void OutputList<T>(IEnumerable<T> list) => list.ToList().ForEach(e => Console.WriteLine(e));

        private static T ReadLine<T>() => (T)Convert.ChangeType(Console.ReadLine(), typeof(T));
        private static IEnumerable<T> ReadLinesList<T>() => Console.ReadLine().Split(' ').Select(i => (T)Convert.ChangeType(i, typeof(T)));

        public static (T, T) ReadLinesTuple2<T>()
        {
            var input = Console.ReadLine().Split(' ');
            return ((T)Convert.ChangeType(input.ElementAt(0), typeof(T)), (T)Convert.ChangeType(input.ElementAt(1), typeof(T)));
        }
        public static (T, T, T) ReadLinesTuple3<T>()
        {
            var input = Console.ReadLine().Split(' ');
            return ((T)Convert.ChangeType(input.ElementAt(0), typeof(T)), (T)Convert.ChangeType(input.ElementAt(1), typeof(T)), (T)Convert.ChangeType(input.ElementAt(2), typeof(T)));
        }
        public static (T, T, T, T) ReadLinesTuple4<T>()
        {
            var input = Console.ReadLine().Split(' ');
            return ((T)Convert.ChangeType(input.ElementAt(0), typeof(T)), (T)Convert.ChangeType(input.ElementAt(1), typeof(T)), (T)Convert.ChangeType(input.ElementAt(2), typeof(T)), (T)Convert.ChangeType(input.ElementAt(3), typeof(T)));
        }
        public static IEnumerable<T> ReadLineNTimes<T>()
        {
            var input = new List<T>();
            var N = long.Parse(Console.ReadLine());
            for (int i = 0; i < N; i++)
            {
                input.Add((T)Convert.ChangeType(Console.ReadLine(), typeof(T)));
            }
            return input;
        }
        public static IEnumerable<T> ReadLineNTimes<T>(long N)
        {
            var input = new List<T>();
            for (int i = 0; i < N; i++)
            {
                input.Add((T)Convert.ChangeType(Console.ReadLine(), typeof(T)));
            }
            return input;
        }
        public static IEnumerable<T> ReadLineNTimes<T>(int N)
        {
            var input = new List<T>();
            for (int i = 0; i < N; i++)
            {
                input.Add((T)Convert.ChangeType(Console.ReadLine(), typeof(T)));
            }
            return input;
        }

        private int SolveDynamicProgramming(int n, IEnumerable<int> valueList)
        {
            var inputList = valueList.ToList();
            var dpList = new List<int>() { 0 };
            for (int i = 0; i < n; ++i)
            {
                dpList.Add(Math.Max(dpList[i], dpList[i] + inputList[i]));
            }

            return dpList[n];
        }

        private int SolveDynamicProgrammingForKnapsack(int n, int weight, List<int> valueList, List<int> weightList)
        {
            var dpList = new List<List<int>>();

            for (int i = 0; i < n + 1; ++i)
            {
                dpList.Add(Enumerable.Repeat(0, weight + 1).ToList());
            }

            for (int i = 0; i < n; ++i)
            {
                for (int w = 0; w <= weight; ++w)
                {
                    if (w >= weightList[i])
                    {
                        dpList[i + 1][w] = Math.Max(dpList[i][w - weightList[i]] + valueList[i], dpList[i][w]);
                    }
                    else
                    {
                        dpList[i + 1][w] = dpList[i][w];
                    }
                }
            }

            return dpList[n][weight];
        }

        public static int Gcd(int a, int b)
        {
            Func<int, int, int> gcd = null;
            gcd = (x, y) => y == 0 ? x : gcd(y, x % y);
            return a > b ? gcd(a, b) : gcd(b, a);
        }

        public static IEnumerable<bool[]> BitFullSearch(int n)
        {
            if (n <= 0)
            {
                yield return new bool[] { };
                yield break;
            }

            for (int i = 0; i < Math.Pow(2, n); i++)
            {
                var array = new bool[n];
                for (int j = 0; j < n; j++)
                {
                    var targetBit = (i >> j) & 1;
                    if (targetBit == 1) array[j] = true;
                }

                yield return array;
            }
        }

        public static IEnumerable<bool[]> BitFullSearch(long n)
        {
            if (n <= 0)
            {
                yield return new bool[] { };
                yield break;
            }

            for (int i = 0; i < Math.Pow(2, n); i++)
            {
                var array = new bool[n];
                for (int j = 0; j < n; j++)
                {
                    var targetBit = (i >> j) & 1;
                    if (targetBit == 1) array[j] = true;
                }

                yield return array;
            }
        }

    }
}


Measured memory_bytes: 51936