Problem:
 Score: 300 points    Problem Statement  M-kun is a student in Aoki High School, where a year is divided into N terms. There is an exam at the end of each term. According to the scores in those exams, a student is given a grade for each term, as follows:   For the first through (K-1) -th terms: not given.  For each of the K -th through N -th terms: the multiplication of the scores in the last K exams, including the exam in the graded term.   M-kun scored A_i in the exam at the end of the i -th term. For each i such that K+1 \leq i \leq N , determine whether his grade for the i -th term is strictly greater than the grade for the (i-1) -th term.      Constraints   2 \leq N \leq 200000  1 \leq K \leq N-1  1 \leq A_i \leq 10^{9}  All values in input are integers.         Input  Input is given from Standard Input in the following format:  N  K  A_1  A_2  A_3  \ldots  A_N       Output  Print the answer in N-K lines. The i -th line should contain Yes if the grade for the (K+i) -th term is greater than the grade for the (K+i-1) -th term, and No otherwise.        Sample Input 1 5 3
96 98 95 100 20      Sample Output 1 Yes
No  His grade for each term is computed as follows:   3 -rd term: (96 \times 98 \times 95) = 893760  4 -th term: (98 \times 95 \times 100) = 931000  5 -th term: (95 \times 100 \times 20) = 190000        Sample Input 2 3 2
1001 869120 1001      Sample Output 2 No  Note that the output should be No if the grade for the 3 -rd term is equal to the grade for the 2 -nd term.       Sample Input 3 15 7
3 1 4 1 5 9 2 6 5 3 5 8 9 7 9      Sample Output 3 Yes
Yes
No
Yes
Yes
No
Yes
Yes

Solution (Python):
import sys, re, os
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import permutations, combinations, product, accumulate
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from fractions import gcd
from bisect import bisect, bisect_left, bisect_right

def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def S_MAP(): return map(str, input().split())
def LIST(): return list(map(int, input().split()))
def S_LIST(): return list(map(str, input().split()))

sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N, K = MAP()
A = LIST()



B = []
tmp = 1


tmp = 1
for i in range(N - K):
    tmp2 = tmp / A[i] * A[K + i]
    if tmp < tmp2:
        print("Yes")
    else:
        print("No")
    
    tmp = 1

Solution (Python):
import sys
import re
import math
import collections
import decimal
import bisect
import itertools
import fractions
import functools
import copy
import heapq
import decimal
import statistics
import queue



sys.setrecursionlimit(10 ** 9)
INF = 10 ** 16
MOD = 10 ** 9 + 7


ni = lambda: int(sys.stdin.readline())
ns = lambda: map(int, sys.stdin.readline().split())
na = lambda: list(map(int, sys.stdin.readline().split()))




def main():
    n, k = ns()
    a = na()

    
    
    
    
    

    for i in range(k, n):
        

        print("Yes" if a[i] > a[i-k] else "No")
        


if __name__ == '__main__':
    main()

Solution (Python):
N,K = map(int,input().split())
A = list(map(int,input().split()))
for i in range(K,N):
    if A[i] > A[i-K]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N,K=map(int,input().split())
a=input().split()
A=[int(b) for b in a]

for k in range(N-K):
    if A[k]<A[k+K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
n, k = map(int, input().split())
li = list(map(int, input().split()))

for i in range(k, n):

    if li[i-k] < li[i]:
        print('Yes')
    else:
        print('No')

Solution (Python):

N, K = map(int,(input().split()))
As = list(map(int,(input().split())))

for i in range(K, N):
    
    if As[i-K] < As[i]:
        print('Yes')
    else:
        print('No')

Solution (Python):
n,k=map(int,input().split())
huga = list(map(int, input().split()))
for i in range(k,n):
    if huga[i]>huga[i-k]:
        print("Yes")
    else:
        print("No")

Solution (Python):
import sys
sys.setrecursionlimit(10 ** 9)

def int1(x): return int(x) - 1
def II(): return int(input())
def MI(): return map(int, input().split())
def MI1(): return map(int1, input().split())
def LI(): return list(map(int, input().split()))
def LI1(): return list(map(int1, input().split()))
def LLI(rows_number): return [LI() for _ in range(rows_number)]
def MS(): return input().split()
def LS(): return list(input())
def LLS(rows_number): return [LS() for _ in range(rows_number)]
def printlist(lst, k=' '): print(k.join(list(map(str, lst))))
INF = float('inf')







def solve():
    N, K = MI()
    A = LI()

    for i in range(K-1, N-1):
        b = A[i-K+1]
        f = A[i+1]
        if f > b:
            print('Yes')
        else:
            print('No')

if __name__ == '__main__':
    solve()

Solution (Python):


"""
Created on Sat Jul 25 20:54:45 2020

@author: naoki
"""

N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(N-K):
    a = A[i]
    b = A[i+K]
    if a<b:
        print("Yes")
    else:
        print("No")

Solution (Python):
from decimal import Decimal

n,k = map(int,input().split())
a = list(map(lambda x:Decimal(int(x)),input().split()))

m = max(a)

for i in range(len(a)):
    a[i] = a[i]/m
temp = Decimal(1)
res = []
for i in range(k):
    temp *= a[i]

res = [temp]
for i in range(k,n):
    temp *= a[i]
    temp /= a[i-k]
    res.append(temp)
for i in range(len(res)-1):
    if(res[i] < res[i+1]):
        print('Yes')
    else:
        print('No')

Solution (Python):
n,k=list(map(int,input().split()))
m=list(map(int,input().split()))
r=1

for i in range(k,n):
  
    if m[i]>m[i-k]:
        print('Yes')
    else:
        print('No')

Solution (Python):
n, k = map(int, input().split())
a = list(map(int, input().split()))

for i in range(k, n):
    if a[i] > a[i - k]:
        print('Yes')
    else:
        print('No')

Solution (Python):
n,k=list(map(int,input().split()))
a=list(map(int,input().split()))

for i in range(n-k):
    if a[i+k]>a[i]:
        print('Yes')
    else:
        print('No')

Solution (Python):


import sys
import math
import time

import collections
from collections import deque
from collections import Counter
import queue
import copy
import bisect
import heapq
import itertools









N, K = map(int, input().split())
A = [int(i) for i in input().split()]
ans = 0

for i in range(K, N):
  ans = A[i]-A[i-K]
  if(ans<=0):
    print("No")
  else:
    print("Yes")

Solution (Python):
n,k = [int(num) for num in input().split()]
a = [int(num) for num in input().split()]

prev_grade = 1.

for i in range(k,n):
    if a[i] > a[i-k]:
        print("Yes")
    else: 
        print("No")

Solution (Python):
def resolve():
    import numpy as np
    n, k = map(int, input().split())
    A = list(map(int, input().split()))
    B = np.cumprod(np.array(A))

    for i in range(n - k):
        if A[i] < A[k + i]:
            print("Yes")
        else:
            print("No")

resolve()

Solution (Python):
n, k = map(int, input().split())
a = list(map(int, input().split()))

ans_list = []

for i in range(n-k):
  if a[i + k] > a[i]:
    ans_list.append('Yes')
  else:
    ans_list.append('No')

for j in range(len(ans_list)):
  print(ans_list[j])

Solution (Python):
from collections import deque
n,k = map(int,input().split())
a = list(map(int,input().split()))
Q = deque()
for i in range(k):
  Q.append(a[i])
for i in range(k,n):
  head = Q.popleft()
  end = a[i]
  if head<end:
    print('Yes')
  else:
    print('No')
  Q.append(end)

Solution (Python):
n, k = map(int, input().split())
a = list(map(int, input().split()))
score = sum(a[:k])
top = 0
for i in range(k, n):
    if a[i] > a[top]:
        print("Yes")
    else:
        print("No")
    top += 1

Solution (Python):




import numpy as np

def int_mtx(N):
    x = []
    for _ in range(N):
        x.append(list(input()))
    return np.array(x)

N,K = map(int,input().split())
A = list(map(int,input().split()))

for i in range(K,N):
    if A[i] > A[i-K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
import os
import heapq
import sys
import math
import operator
from collections import defaultdict
from io import BytesIO, IOBase


"""def gcd(a,b):
    if b==0:
        return a
    else:
        return gcd(b,a%b)"""

"""def pw(a,b):
    result=1
    while(b>0):
        if(b%2==1): result*=a
        a*=a
        b//=2
    return result"""



def inpt():
    return [int(k) for k in input().split()]


def main():
    n,k=map(int,input().split())
    ar=inpt()
    j=0
    for i in range(k,n):
        if(ar[j]<ar[i]):
            print('Yes')
        else:
            print('No')
        j+=1


BUFSIZE = 8192


class FastIO(IOBase):
    newlines = 0

    def __init__(self, file):
        self._fd = file.fileno()
        self.buffer = BytesIO()
        self.writable = "x" in file.mode or "r" not in file.mode
        self.write = self.buffer.write if self.writable else None

    def read(self):
        while True:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            if not b:
                break
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines = 0
        return self.buffer.read()

    def readline(self):
        while self.newlines == 0:
            b = os.read(self._fd, max(os.fstat(self._fd).st_size, BUFSIZE))
            self.newlines = b.count(b"\n") + (not b)
            ptr = self.buffer.tell()
            self.buffer.seek(0, 2), self.buffer.write(b), self.buffer.seek(ptr)
        self.newlines -= 1
        return self.buffer.readline()

    def flush(self):
        if self.writable:
            os.write(self._fd, self.buffer.getvalue())
            self.buffer.truncate(0), self.buffer.seek(0)


class IOWrapper(IOBase):
    def __init__(self, file):
        self.buffer = FastIO(file)
        self.flush = self.buffer.flush
        self.writable = self.buffer.writable
        self.write = lambda s: self.buffer.write(s.encode("ascii"))
        self.read = lambda: self.buffer.read().decode("ascii")
        self.readline = lambda: self.buffer.readline().decode("ascii")


sys.stdin, sys.stdout = IOWrapper(sys.stdin), IOWrapper(sys.stdout)
input = lambda: sys.stdin.readline().rstrip("\r\n")

if __name__ == "__main__":
    main()

Solution (Python):

def main():
  n, k = map(int, input().split())
  A = tuple(map(int, input().split()))

  for i in range(k, n):
    if A[i] > A[i - k]:
      print('Yes')
    else:
      print('No')



main()

Solution (Python):
NK = list(map(int, input().split()))
A = list(map(int, input().split()))

first = 0
last = 0

for i in range(NK[1], NK[0]):
    first = A[i - NK[1]]
    last = A[i]
    if (first < last):
        print("Yes")
    else:
        print("No")

Solution (Python):


import functools


def judge(n, k, bs):
    for i in range(k, n):
        prev_first = bs[i - k]
        new_last = bs[i]
        yield prev_first < new_last


def main():
    n, k = (int(x) for x in input().split())
    bs = [int(b) for b in input().split()]
    for res in judge(n, k, bs):
        if res:
            print("Yes")
        else:
            print("No")


if __name__ == '__main__':
    main()

Solution (Python):
def readinput():
    n,k=map(int,input().split())
    a=list(map(int,input().split()))
    return n,k,a

def main(n,k,a):
    for i in range(n-k):
        if a[i]<a[i+k]:
            print('Yes')
        else:
            print('No')

if __name__=='__main__':
    n,k,a=readinput()
    main(n,k,a)

Solution (Python):
n,k=map(int,input().split())
a=list(map(int,input().split()))
for i in range(n-k):
    if a[i]<a[i+k]:
        print("Yes")
    else:
        print("No")

Solution (Python):


def main():
    n, k = map(int, input().split())
    a = list(map(int, input().split()))
    for i in range(k, n):
        if a[i-k] < a[i]:
            print("Yes")
        else:
            print("No")

if __name__ == '__main__':
    main()

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(K, N):
    if A[i-K] < A[i]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

for i,j in zip(range(K, N), range(N-K)):
    print("Yes" if A[i] > A[j] else "No")

Solution (Python):
n, k = map(int, input().split())
a = list(map(int, input().split()))

for i in range(k, n):
  p = a[i-k]
  c = a[i]
  if p < c:
    print('Yes')
  else:
    print('No')

Solution (Python):
N,K = map(int, input().split())
A = [int(i) for i in input().split()]


for i in range(K,N):
  
  if A[i-K]<A[i]:
    print("Yes")
  else:
    print("No")

Solution (Python):
import math as m

n,k = map(int,input().split())
a = list(map(int,input().split()))
prev = 1
for i in range(k):
  prev += m.log(a[i])
for i in range(k,n):
  cur = prev + m.log(a[i])
  cur -= m.log(a[i-k])
  print("Yes" if cur > prev else "No")
  prev = cur

Solution (Python):



def m():
    N, K = map(int, input().split())
    A = list(map(int, input().split()))
    for i in range(N-K):
        left = A[i]
        right = A[K+i]
        if left < right:
            print('Yes')
        else:
            print('No')


m()

Solution (Python):
N, K = map(int, input().split())
scores = list(map(int, input().split())) 


for i in range(K, N):
    bef = scores[i - K]
    aft = scores[i]

    if aft > bef:
        print('Yes')
    else:
        print('No')

Solution (Python):
n,k=map(int,input().split())
a=[1] + list(map(int,input().split()))

for i in range(k+1,n+1):
    if a[i]>a[i-k]:
        print("Yes")
    else:
        print("No")

Solution (Python):
n, k = map(int, input().split())
As = list(map(int, input().split()))

for i in range(k,n):
    if As[i] > As[i - k]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N,K=map(int,input().split())
A=list(map(int,input().split()))
for i in range(N-K):
    num=K+i
    if A[num]/A[i]>1:
        print('Yes')
    else:
        print('No')

Solution (Python):
n,k = map(int,input().split())
a= list(map(int,input().split()))

for i in range(k,n):
    if a[i-k]>= a[i]:
        print("No")
    else:
        print("Yes")

Solution (Python):
n,k=map(int,input().split())
arr=list(map(int,input().split()))
for i in range(n):
    if i>=k:
        if arr[i-k]<arr[i]:
            print("Yes")
        else:
            print("No")

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(0,N-K):
    print("Yes" if A[K+i]>A[i] else "No")

Solution (Python):

n,k=map(int,input().split())
a=[int(i) for i in input().split()]
for i in range(n-k):
    if a[i]<a[i+k]:
        print("Yes")
    else:
        print("No")

Solution (Python):
import sys, re
from math import ceil, floor, sqrt, pi, factorial, gcd
from copy import deepcopy
from collections import Counter, deque
from heapq import heapify, heappop, heappush
from itertools import accumulate, product, combinations, combinations_with_replacement
from bisect import bisect, bisect_left, bisect_right
from functools import reduce
from decimal import Decimal, getcontext

def i_input(): return int(input())
def i_map(): return map(int, input().split())
def i_list(): return list(i_map())
def i_row(N): return [i_input() for _ in range(N)]
def i_row_list(N): return [i_list() for _ in range(N)]
def s_input(): return input()
def s_map(): return input().split()
def s_list(): return list(s_map())
def s_row(N): return [s_input for _ in range(N)]
def s_row_str(N): return [s_list() for _ in range(N)]
def s_row_list(N): return [list(s_input()) for _ in range(N)]
def lcm(a, b): return a * b // gcd(a, b)
sys.setrecursionlimit(10 ** 6)
INF = float('inf')
MOD = 10 ** 9 + 7
num_list = []
str_list = []

def main():
    n, k = i_map()
    num_list = i_list()

    for i in range(n-k):
        if num_list[i] < num_list[i+k]:
            print('Yes')
        else:
            print('No')

if __name__ == '__main__':
    main()

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(N-K):
    if A[K+i] > A[i]:
        print('Yes')
    else:
        print('No')

Solution (Python):
from math import sqrt,ceil,gcd
def ii():return int(input())
def si():return input()
def mi():return map(int,input().split())
def li():return list(mi())




n,k=mi()
a=li()
for i in range(k,n):
    if a[i]>a[i-k]:
        print('Yes')
    else:
        print('No')

Solution (Python):
N,K=map(int,input().split())
A=list(map(int,input().split()))

for i in range(N-K):
    if A[i]<A[i+K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
N,K = map(int,input().split())
A = [int(i) for i in input().split()]
for i in range(N-K):
    if A[i] < A[i+K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
N,K = map(int, input().split())
A_list = list(map(int, input().split()))
for i in range(N - K):
    if A_list[i] < A_list[i + K]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(N - K):
    if A[K + i] > A[i]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N, K = map(int, input().split())
A = [int(i) for i in input().split()]

for i in range(N-K):
    if A[i] < A[i+K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
n,k=map(int,input().split())
A=list(map(int,input().split()))
ave=[0 for i in range(n-k+1)]


for i in range(n-k):
    if A[i+k]>A[i]:
        print('Yes')
    else:
        print('No')

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

score = 1
for i in range(N - K):
    if A[i] < A[i + K]:
        print("Yes")
    else:
        print("No")

Solution (Python):
def resolve():
    N,K = map(int,input().split())
    A = input().split()
    for i in range(K,N):
        if int(A[i]) > int(A[i-K]):
            print("Yes")
        else:
            print("No")
resolve()

Solution (Python):
n,k = map(int,input().split())
a = list(map(int,input().split()))
    
for i in range(k,n):
    if a[i-k] < a[i]:
        print("Yes")
        
    else:
        print("No")

Solution (Python):
import sys
input = sys.stdin.readline

'''

'''

def solve(n, k, a):
    res = []

    for i in range(k, n):
        if a[i-k] < a[i]:
            res.append("Yes")
        else:
            res.append("No")
    
    return res

n, k = map(int, input().split())
a = list(map(int, input().split()))

res = solve(n, k, a)
for r in res:
    print(r)

Solution (Python):
def read():
    N, K = map(int, input().split())
    A = list(map(int, input().split()))
    return N, K, A

def solve(N, K, A):
    for i in range(N-K):
        if A[i] < A[i+K]:
            print("Yes")
        else:
            print("No")


if __name__ == '__main__':
    inputs = read()
    solve(*inputs)

Solution (Python):
import sys
readline=sys.stdin.readline

N,K = map(int,readline().split())
A=list(map(int,readline().split()))



for i in range(K, N):
  if A[i - K] < A[i]:
    print("Yes")
  else:
    print("No")

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))
for i in range(K, N):
    
    if A[i] > A[i - K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
ma = lambda :map(int,input().split())
ni = lambda:int(input())
yn = lambda fl:print("Yes") if fl else print("No")
import collections
import math
import itertools
import heapq as hq
n,k = ma()
A = list(ma())
s = 1
zeros = [0 for i in range(n+1)]
for i in range(k):
    if A[i] ==0:
        zeros[i] +=1
        zeros[min(n,i+k)] -=1
for i in range(1,n+1):
    zeros[i] += zeros[i-1]
for i in range(k,n):
    if zeros[i] >0:
        f = False
        yn(f)
        continue
    if A[i] > A[i-k]:
        f =True
    else:
        f=False
    yn(f)

Solution (Python):
n,k=map(int,input().split())
a=list(map(int,input().split()))
s=sum(a[:k])
for i in range(n-k):
	t=s-a[i]+a[k+i]
	print('YNeos'[s>=t::2])
	s=t

Solution (Python):
from collections import Counter
from collections import defaultdict
from collections import deque
from functools import reduce
import math
import itertools
import heapq

import bisect
import sys

sys.setrecursionlimit(10**6)


def bfs(s, n, node):
    
    check = [False for _ in range(n)]
    check[s] = True
    
    queue = deque([s])
    visited_num = 1

    
    
    color = [-1 for _ in range(n)]
    color[s] = 0

    while visited_num < n:
        
        if len(queue) == 0:
            
            
            return color

        now_vertex = queue.popleft()
        
        for next_vertex in node[now_vertex]:

            if check[next_vertex] == True:
                continue

            queue.append(next_vertex)
            check[next_vertex] = True

            
            color[next_vertex] = color[now_vertex]+1
            visited_num += 1

    return color


mod = 10**9+7



def ceil(x, y): return (x+y-1)//y
def input_list(): return list(map(int, input().split()))


def buy(buy_cost, sell_cost, money):
    return money % buy_cost+(money//buy_cost)*sell_cost


n, k = input_list()
a = input_list()

for i in range(n-k):
    if a[i] < a[i+k]:
        print("Yes")
    else:
        print("No")

Solution (Python):

import sys, math
from itertools import permutations, combinations
from collections import defaultdict, Counter, deque
from math import factorial
from bisect import bisect_left, bisect_right 
sys.setrecursionlimit(10**7)
enu = enumerate
MOD = 10**9+7
def input(): return sys.stdin.readline()[:-1]
pl = lambda x: print(*x, sep='\n')

N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(N-K):
    if A[i] < A[i+K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
def solve():
    N, K = map(int,input().split())
    A = list(map(int,input().split()))
    
    for i in range(K,N):
        if A[i-K] < A[i]:
            print('Yes')
        else:
            print('No')

if __name__ == '__main__':
    solve()

Solution (Python):
n,k  = [int(x) for x in input().split()]
a = [int(x) for x in input().split()]
for i in range(n-k):
    ele = a[i+k]
    if ele<=a[i]:
        print("No")
    else:
        print("Yes")

Solution (Python):
N, K = [int(s) for s in input().split()]
A = [int(s) for s in input().split()]

for i in range(K, N):
    print('Yes' if A[i] - A[i - K] > 0 else 'No')

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(K, N):
    if A[i-K] < A[i]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N,K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(K,N):
    if A[i-K] < A[i]:
        print('Yes')
    else:
        print('No')

Solution (Python):
def getN():
    return int(input())
def getNM():
    return map(int, input().split())
def getList():
    return list(map(int, input().split()))
def getArray(intn):
    return [int(input()) for i in range(intn)]
def input():
    return sys.stdin.readline().rstrip()
def rand_N(ran1, ran2):
    return random.randint(ran1, ran2)
def rand_List(ran1, ran2, rantime):
    return [random.randint(ran1, ran2) for i in range(rantime)]
def rand_ints_nodup(ran1, ran2, rantime):
  ns = []
  while len(ns) < rantime:
    n = random.randint(ran1, ran2)
    if not n in ns:
      ns.append(n)
  return sorted(ns)

def rand_query(ran1, ran2, rantime):
  r_query = []
  while len(r_query) < rantime:
    n_q = rand_ints_nodup(ran1, ran2, 2)
    if not n_q in r_query:
      r_query.append(n_q)
  return sorted(r_query)

from collections import defaultdict, deque, Counter
from sys import exit
from decimal import *
import heapq
from math import sqrt, pi
from fractions import gcd
import random
import string
import copy
from itertools import combinations, permutations, product
from operator import mul, itemgetter
from functools import reduce
from bisect import bisect_left, bisect_right

import sys
sys.setrecursionlimit(1000000000)
mod = 10 ** 9 + 7





N, K = getNM()
A = getList()

for i in range(0, N - K):
    if A[i] < A[i + K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
n,k=map(int,input().split())
a=list(map(int,input().split()))



for i in range(k,len(a)):
  
  
  if a[i]>a[i-k]:
    print("Yes")
  else:
    print("No")

Solution (Python):


N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(N-K):
    if A[i]< A[i+K]:
        print("Yes")
    else:
        print("No")

Solution (Python):
n, k = map(int, input().split())
A = list(map(int, input().split()))

for j in range(n - k):
    if A[k + j] > A[j]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N, K = map(int, input().split())
A = [int(a) for a in input().split()]

for i in range(N-K):
    if A[K+i] > A[i]:
        print('Yes')
    else:
        print('No')

Solution (Python):
n, k = map(int, input().split())
A = list(map(int, input().split()))

for i in range(k, n):
    if A[i-k] < A[i]:
        print("Yes")
    else:
        print("No")

Solution (Python):
from sys import stdin
import sys
import math
import random
from decimal import Decimal
import itertools as it


N, K = [int(x) for x in stdin.readline().rstrip().split()]
A = list(map(int, input().split()))
for i in range(K, N):
    if A[i-K] >= A[i]:
        print("No")
    else:
        print("Yes")

Solution (Python):
import math

N,K=list(map(int,input().split()))
A=list(map(int,input().split()))

for i in range(0,N-K):
    if A[i] < A[i+K]:
        print("Yes")
    else:
        print("No")

Solution (Python):
n,k = map(int,input().split())
a = list(map(int,input().split()))

for i in range(n-k):
    if a[i] < a[i+k]:
        print('Yes')
    else:
        print('No')

Solution (Python):

N,K = map(int,input().split())
A = list(map(int,input().split()))

for i in range(K,N):
    if A[i]>A[i-K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(K, N):
  if A[i-K] < A[i]:
    print('Yes')
  else:
    print('No')

Solution (Python):
N,K=map(int,input().split())
A=list(map(int,input().split()))

for i in range(K,N):
    if A[i]>A[i-K]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

ans = []
for rem_ix in range(0, N-K):
    remove = A[rem_ix]
    insert = A[K+rem_ix]
    
    
    if remove < insert:
        ans.append("Yes")
    else:
        ans.append("No")

print(*ans, sep='\n')

Solution (Python):
N, K=map(int,input().split())
scores=input().split()
for i in range(N):
  scores[i]=int(scores[i])
new=K
old=0
while new<N:
  if scores[new]>scores[old]:
    print("Yes")
  else:
    print("No")
  new+=1
  old+=1

Solution (Python):
n, k = map(int, input().split())
l = list(map(int, input().split()))
for i in range(k, n):
    if l[i] > l[i - k]: print('Yes')
    else: print('No')

Solution (Python):
from numpy import *
N,K = map(int,input().split())
A = log(array(list(map(int,input().split()))))
B = [sum(A[:K])]

for n in range(N-K):
  B+=[B[-1]+A[n+K]-A[n]]
  
  if B[n]<B[n+1]:
    print("Yes")
  else:
    print("No")

Solution (Python):

import copy
N, K = map(int, input().split())
A = list(map(int, input().split()))

before = 0
for i in range(K, 0, -1):
    before += A[K-i]
for i in range(K, N):
    after = (before-A[i-K])+A[i]
    if before < after:
        print('Yes')
    else:
        print('No')
    before = copy.deepcopy(after)

Solution (Python):
N, K = map(lambda x: int(x), input().split(" "))
As = list(map(lambda x: int(x), input().split(" ")))

for i in range(len(As)):
    if i >= K:
        if As[i] > As[i-K]:
            print("Yes")
        else:
            print("No")

Solution (Python):
n,k = map(int, input().split())
a = list(map(int, input().split()))
for i in range(n-k):
  if(a[i]>=a[k+i]):
    print("No")
  else:
    print("Yes")

Solution (Python):
N, K=map(int, input().split())
A=[0]+list(map(int, input().split()))
zerorui=[0]*(N+1)
for i in range(1, N+1):
  if A[i]==0:
    zerorui[i]=zerorui[i-1]+1
  else:
    zerorui[i]=zerorui[i-1]
    
for i in range(K+1, N+1):
  if zerorui[i]-zerorui[i-K]>0:
    print('No')
  elif A[i]>A[i-K]:
    print('Yes')
  else:
    print('No')

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(N-K):
    if A[K+i] > A[i]:
        print('Yes')
    else:
        print('No')

Solution (Python):
N,K = map(int,input().split())
A = list(map(int,input().split()))
for i in range(0,N - K):
    if A[K + i] <= A[i]:
        print("No")
    else:
        print("Yes")

Solution (Python):

n,k  = map(int, input().split())
a =  list(map(int, input().split()))

for i in range(n-k):
    if a[i]<a[k+i]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))
for i in range(K + 1, N + 1):
    if A[i - K - 1] < A[i - 1]:
        print("Yes")
    else:
        print("No")

Solution (Python):
from math import log2
n,k=map(int,input().split())
ar=list(map(int,input().split()))
for i in range(n):
    ar[i]=log2(ar[i])
prod=0
for i in range(k):
    prod+=ar[i]
for i in range(k,n):
    x=prod+ar[i]-ar[i-k]
    if x>prod:
        print('Yes')
    else:
        print('No')
    prod=x

Solution (Python):
n,k=(int(i) for i in input().split())
l=[int(i) for i in input().split()]
for i in range(k,n):
    if(l[i]>l[i-k]):
        print("Yes")
    else:
        print("No")

Solution (Python):
n, k = map(int, input().split())
li_a = list(map(int, input().split()))
if k == 1:
    for i in range(1, n):
        if li_a[i] > li_a[i-1]:
            print('Yes')
        else:
            print('No')
else:
    for i in range(k, n):
        if li_a[i-k] < li_a[i]:
            print('Yes')
        else:
            print('No')

Solution (Python):
n,k=map(int,input().split())
a=list(map(int,input().split()))

for i in range(k,n):
  x=a[i-k]
  yy=a[i]
  if x<yy:
    print('Yes')
  else:
    print('No')

Solution (Python):
n, k = map(int, input().split())
ls = [int(x) for x in input().split()]
dp = sum(ls[0:k])
for i in range(0,len(ls)-k):
    tmp = dp + ls[i+k] - ls[i]
    if tmp > dp:
        print("Yes")
    else:
        print("No")
    dp = tmp

Solution (Python):

import sys
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
read = sys.stdin.buffer.read
sys.setrecursionlimit(10 ** 7)
INF = float('inf')

N, K = map(int, input().split())
A = list(map(int, input().split()))

score = sum(A[:K])
old_score = score

for i, j in enumerate(range(K, N)):
    score = score - A[i] + A[j]
    
    if score > old_score:
        print('Yes')
    else:
        print('No')
    old_score = score

Solution (Python):
n,k = map(int, input().split(" "))
a = list(map(int, input().split(" ")))
suma = []
for i in range(n - k):
  if a[i] < a[i + k]:
    print("Yes")
  else:
    print("No")

Solution (Python):
N, K = list(map(int, input().split()))
As = list(map(int, input().split()))

for i in range(K,N):

    if(As[i] > As[i - K]):
        print("Yes")
    
    else:
        print("No")

Solution (Python):

n,k=map(int,input().split())
a=list(map(int,input().split()))

for i in range(n-k):
    if a[i]<a[i+k]:
        print("Yes")
    else:
        print("No")

Solution (Python):
N, K = map(int, input().split())
A = list(map(int, input().split()))

for i in range(K, N):
    if A[i-K] < A[i]:
        print('Yes')
    else:
        print('No')