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):
n,k=map(int,input().split())
a=list(map(int,input().split()))
for i in range(n-k):
	print("Yes" if a[i]<a[i+k] 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(N - K):
    if A[i] < A[i + K]: print("Yes")
    else: print("No")

Solution (Python):
import math
import sys
from itertools import permutations
input = sys.stdin.readline

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

for i in range(K,N):
    if arr[i]>arr[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())
As = list(map(int, input().split()))
for i in range(K, N):
    print("Yes" if As[i] > As[i-K] else "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] > A[i - k]:
            print('Yes')
        else:
            print('No')

if __name__ == '__main__':
    main()

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

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

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]:
        ans="Yes"
    else:
        ans="No"
    print(ans)

Solution (Python):
N,K = [int(i) for i in 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):
from math import gcd

from math import factorial as f

from math import ceil, floor, sqrt
import math

import bisect
import re
import heapq

from copy import deepcopy
import itertools
from itertools import permutations

from sys import exit

ii = lambda: int(input())
mi = lambda: map(int, input().split())
li = lambda: list(map(int, input().split()))

yes = "Yes"
no = "No"


def main():
    n, k = mi()
    a = li()

    for i in range(k, n):
        if a[i] > a[i - k]:
            print(yes)
        else:
            print(no)


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):
def resolve():
    n, k = map(int, input().split())
    a = list(map(int, input().split()))
    for i in range(n - k):
        print("Yes" if a[i] < a[i + k] else "No")


if __name__ == '__main__':
    resolve()

Solution (Python):
import sys

def solve():
      input = sys.stdin.readline
      N, K = map(int, input().split())
      A = [int(a) for a in input().split()]
      Ans = ["No"] * (N - K)
      for i in range(K, N):
            if A[i] > A[i - K]:
                  Ans[i - K] = "Yes"
      print(*Ans, sep = "\n")

      return 0

if __name__ == "__main__":
      solve()

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

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

Solution (Python):
def main():
    N, K = map(int, input().split())
    A = list(map(int, input().split()))
    for a, b in zip(A, A[K:]):
        print('Yes' if b > a else 'No')

main()

Solution (Python):



def ri():
    return int(input())

def rl():
    return list(input().split())

def rli():
    return list(map(int, input().split()))

def main():
    n, k = rli()
    la = rli()
    for i in range(k, n):
        if la[i] > la[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[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):
N, K = map(int, input().split())
A = list(map(int, input().split()))
for i in range(N-K):
    print('Yes' if A[i+K]>A[i] 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] > 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(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()))

a0 = a[:n-k]
a1 = a[k:]

ans = []

for x,y in zip(a0,a1):
    if(x<y):
        ans.append('Yes')
    else:
        ans.append('No')

print('\n'.join(ans))

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

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

Ans = ['Yes']*(N-K)
for i in range(N-K):
    if A[i] >= A[K+i]:
        Ans[i] = 'No'

print('\n'.join(Ans))

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
import heapq
import math
import fractions
import bisect
import itertools
from collections import Counter
from collections import deque
from operator import itemgetter
def input(): return sys.stdin.readline().strip()
def mp(): return map(int,input().split())
def lmp(): return list(map(int,input().split()))

n,k=mp()
a=lmp()
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())
arr=list(map(int,input().split()))
for i in range(k,n):
  if arr[i]>arr[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):
    print("YNeos"[A[i]<=A[i-K]::2])

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())
alist=list(map(int,input().split()))

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

Solution (Python):
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians, gcd
from itertools import accumulate, permutations, combinations, product, groupby, combinations_with_replacement
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from heapq import heappush, heappop
from functools import reduce
def input(): return sys.stdin.readline().strip()
def INT(): return int(input())
def MAP(): return map(int, input().split())
def LIST(): return list(map(int, input().split()))
def ZIP(n): return zip(*(MAP() for _ in range(n)))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

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

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

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

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

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

Solution (Python):
import bisect
import cmath
import heapq
import itertools
import math
import operator
import os
import random
import re
import string
import sys
from collections import Counter, defaultdict, deque
from copy import deepcopy
from decimal import Decimal
from functools import lru_cache, reduce
from math import gcd
from operator import add, itemgetter, mul, xor

import numpy as np

if os.getenv("LOCAL"):
    sys.stdin = open("_in.txt", "r")

sys.setrecursionlimit(10 ** 9)
INF = float("inf")
IINF = 10 ** 18
MOD = 10 ** 9 + 7


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

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

Solution (Python):
import sys; input = sys.stdin.buffer.readline
sys.setrecursionlimit(10**7)
from collections import defaultdict
con = 10 ** 9 + 7; INF = float("inf")

def getlist():
	return list(map(int, input().split()))


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

if __name__ == '__main__':
	main()

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

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

Solution (Python):


import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**7)
from collections import Counter, deque
from collections import defaultdict
from itertools import combinations, permutations, accumulate, groupby, product
from bisect import bisect_left,bisect_right
from heapq import heapify, heappop, heappush
from math import floor, ceil,pi,factorial,sin
from operator import itemgetter
def I(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))
def LI2(): return [int(input()) for i in range(n)]
def MXI(): return [[LI()]for i in range(n)]
def SI(): return input().rstrip()
def printns(x): print('\n'.join(x))
def printni(x): print('\n'.join(list(map(str,x))))
inf = 10**17
mod = 10**9 + 7

n,k=MI()
lis=LI()
for i in range(n-k):
    if lis[i]<lis[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+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(N-K):
  if A[i+K] > A[i]:
    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] > a[i - k]:
            print("Yes")
        else:
            print("No")


if __name__ == '__main__':
    main()

Solution (Python):
def II(): return int(input())
def MI(): return map(int, input().split())
def LI(): return list(map(int, input().split()))

N,K=MI()
L=LI()
for i in range(N-K):
  if L[i]<L[i+K]:
    print('Yes')
  else:
    print('No')

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

N, K = map(int, input().split())
A = list(map(lambda x : log(int(x)), input().split()))
s = 0
for i in range(K):
    s += A[i]
for i in range(K, N):
    t = s - A[i-K] + A[i]
    if t > s:
        print('Yes')
    else:
        print('No')
    s = t

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

Solution (Python):
import sys

readline = sys.stdin.readline
readall = sys.stdin.read
ns = lambda: readline().rstrip()
ni = lambda: int(readline().rstrip())
nm = lambda: map(int, readline().split())
nl = lambda: list(map(int, readline().split()))
prn = lambda x: print(*x, sep='\n')

def solve():
    n, k = nm()
    a = nl()
    for i in range(n-k):
        if a[i+k] > a[i]:
            print('Yes')
        else:
            print('No')
    return

solve()

Solution (Python):






import sys
input = sys.stdin.readline

import math

import bisect
import heapq
from collections import defaultdict
from collections import deque
from collections import Counter
from functools import lru_cache





MOD = 10**9+7
INF = float('inf')
AZ = "abcdefghijklmnopqrstuvwxyz"






def I(): return int(input().strip())
def S(): return input().strip()
def IL(): return list(map(int,input().split()))
def SL(): return list(map(str,input().split()))
def ILs(n): return list(int(input()) for _ in range(n))
def SLs(n): return list(input().strip() for _ in range(n))
def ILL(n): return [list(map(int, input().split())) for _ in range(n)]
def SLL(n): return [list(map(str, input().split())) for _ in range(n)]


def P(arg): print(arg); return
def Y(): print("Yes"); return
def N(): print("No"); return
def E(): exit()
def PE(arg): print(arg); exit()
def YE(): print("Yes"); exit()
def NE(): print("No"); exit()


def DD(arg): return defaultdict(arg)


def inv(n): return pow(n, MOD-2, MOD)


kaijo_memo = []
def kaijo(n):
  if(len(kaijo_memo) > n): return kaijo_memo[n]
  if(len(kaijo_memo) == 0): kaijo_memo.append(1)
  while(len(kaijo_memo) <= n): kaijo_memo.append(kaijo_memo[-1] * len(kaijo_memo) % MOD)
  return kaijo_memo[n]

gyaku_kaijo_memo = []
def gyaku_kaijo(n):
  if(len(gyaku_kaijo_memo) > n): return gyaku_kaijo_memo[n]
  if(len(gyaku_kaijo_memo) == 0): gyaku_kaijo_memo.append(1)
  while(len(gyaku_kaijo_memo) <= n): gyaku_kaijo_memo.append(gyaku_kaijo_memo[-1] * pow(len(gyaku_kaijo_memo),MOD-2,MOD) % MOD)
  return gyaku_kaijo_memo[n]

def nCr(n,r):
  if n == r: return 1
  if n < r or r < 0: return 0
  ret = 1
  ret = ret * kaijo(n) % MOD
  ret = ret * gyaku_kaijo(r) % MOD
  ret = ret * gyaku_kaijo(n-r) % MOD
  return ret


def factorization(n):
  arr = []
  temp = n
  for i in range(2, int(-(-n**0.5//1))+1):
    if temp%i==0:
      cnt=0
      while temp%i==0: 
        cnt+=1 
        temp //= i
      arr.append([i, cnt])
  if temp!=1: arr.append([temp, 1])
  if arr==[]: arr.append([n, 1])
  return arr


def make_divisors(n):
  divisors = []
  for i in range(1, int(n**0.5)+1):
    if n % i == 0:
      divisors.append(i)
      if i != n // i: 
        divisors.append(n//i)
  return divisors


def make_primes(N):
  max = int(math.sqrt(N))
  seachList = [i for i in range(2,N+1)]
  primeNum = []
  while seachList[0] <= max:
    primeNum.append(seachList[0])
    tmp = seachList[0]
    seachList = [i for i in seachList if i % tmp != 0]
  primeNum.extend(seachList)
  return primeNum


def gcd(a, b):
    while b: a, b = b, a % b
    return a


def lcm(a, b):
    return a * b // gcd (a, b)


def count_bit(n):
  count = 0
  while n:
    n &= n-1
    count += 1
  return count


def base_10_to_n(X, n):
  if X//n: return base_10_to_n(X//n, n)+[X%n]
  return [X%n]

def base_n_to_10(X, n):
  return sum(int(str(X)[-i-1])*n**i for i in range(len(str(X))))

def base_10_to_n_without_0(X, n):
  X -= 1
  if X//n: return base_10_to_n_without_0(X//n, n)+[X%n]
  return [X%n]


def int_log(n, a):
  count = 0
  while n>=a:
    n //= a
    count += 1
  return count





N,K = IL()
A = IL()

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

Solution (Python):


import sys
input=sys.stdin.readline

def main():
    N,K=map(int,input().split())
    A=[0]+list(map(int,input().split()))
    for i in range(K+1,N+1):
        if A[i]>A[i-K]:
            print("Yes")
        else:
            print("No")
    
    
    
if __name__=="__main__":
    main()

Solution (Python):
def main():
    N, K = map( int,input().split())
    A = list( map( int, input().split()))
    ANS = []
    for i in range(K,N):
        if A[i-K] < A[i]:
            ANS.append("Yes")
        else:
            ANS.append("No")
    print("\n".join(ANS))
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[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):
N,K=map(int,input().split())
A=list(map(int,input().split()))
print(*[['No','Yes'][A[i+K]>A[i]] for i in range(N-K)],sep='\n')

Solution (Python):
n,k = 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
input = sys.stdin.readline

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

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

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

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

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

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(n-k):
    if a[i] >= a[i+k]:
        print("No")
    else:
        print("Yes")

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

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 sys

read = sys.stdin.read
readline = sys.stdin.readline
readlines = sys.stdin.readlines
sys.setrecursionlimit(10 ** 9)
INF = 1 << 60
MOD = 1000000007


def main():
    N, K, *A = map(int, read().split())

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

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


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):
import sys

readline = sys.stdin.readline
MOD = 10 ** 9 + 7
INF = float('INF')
sys.setrecursionlimit(10 ** 5)


def main():
    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")


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[i+k] > a[i]:
        print("Yes")
    else:
        print("No")

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


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] > A[i - K]:
        print('Yes')
    else:
        print('No')

Solution (Python):
n, k = map(int, input().split())
a = [0] + 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):
def examA():
    X = I()
    X -= 400
    ans = 8 - X//200
    print(ans)
    return

def examB():
    A, B, C = LI()
    K = I()
    cnt = 0
    while(A>=B):
        B *= 2
        cnt += 1
    while(B>=C):
        C *= 2
        cnt += 1

    if cnt<=K:
        print("Yes")
    else:
        print("No")
    return

def examC():
    N, K = LI()
    A = LI()
    ans = ["Yes"]*(N-K)
    for i in range(N-K):
        if A[i+K]<=A[i]:
            ans[i] = "No"
    for v in ans:
        print(v)
    return

def examD():
    ans = 0
    print(ans)
    return

def examE():
    ans = 0
    print(ans)
    return

def examF():
    ans = 0
    print(ans)
    return

from decimal import getcontext,Decimal as dec
import sys,bisect,itertools,heapq,math,random
from copy import deepcopy
from heapq import heappop,heappush,heapify
from collections import Counter,defaultdict,deque
read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
def I(): return int(input())
def LI(): return list(map(int,sys.stdin.readline().split()))
def DI(): return dec(input())
def LDI(): return list(map(dec,sys.stdin.readline().split()))
def LSI(): return list(map(str,sys.stdin.readline().split()))
def LS(): return sys.stdin.readline().split()
def SI(): return sys.stdin.readline().strip()
global mod,mod2,inf,alphabet,_ep
mod = 10**9 + 7
mod2 = 998244353
inf = 10**18
_ep = dec("0.000000000001")
alphabet = [chr(ord('a') + i) for i in range(26)]
alphabet_convert = {chr(ord('a') + i): i for i in range(26)}

getcontext().prec = 28

sys.setrecursionlimit(10**7)

if __name__ == '__main__':
    examC()

"""
142
12 9 1445 0 1
asd dfg hj o o
aidn
"""

Solution (Python):
mod = 1000000007
eps = 10**-9


def main():
    import sys
    input = sys.stdin.readline

    N, K = 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")


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):

import sys
from collections import deque, Counter
from heapq import heappop, heappush
from bisect import bisect_right
from itertools import accumulate

sys.setrecursionlimit(10**6)
INF = 10**12
m = 10**9 + 7

def main():
    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')

if __name__ == "__main__":
    main()

Solution (Python):
n, k, *a = map(int, open(0).read().split())

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

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

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

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

ans = []
for i in range(k, n):
    if a[i - k] < a[i]:
        ans.append('Yes')
    else:
        ans.append('No')

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

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

Solution (Python):


import sys
read = sys.stdin.read
readline = sys.stdin.readline

n,k,*a = map(int, read().split())

for i,j in zip(a,a[k:]):
    if i < j:
        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] < 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()))

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

print("\n".join(X))

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):
import sys
input = sys.stdin.readline
n,k = map(int,input().split())
A = list(map(int,input().split()))

for i in range(n-k):
    print("Yes" if A[i] < A[i+k] else "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):
from collections import deque
import math

def Next(): return input()
def NextInt(): return int(Next())
def NextInts(): return map(int,input().split())
def Nexts(): return map(str,input().split())
def NextIntList(): return list(map(int,input().split()))
def RowInts(n): return [input() for i in range(n)]

n, k = NextInts()
da = NextIntList()

for i in range(k, n):
    if da[i] > da[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(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,n):
  if a[i-k] < a[i]:
    print('Yes')
  else:
    print('No')

Solution (Python):

from collections import defaultdict, deque
from heapq import heappush, heappop
from itertools import permutations, accumulate
import sys
import math
import bisect
def LI(): return [int(x) for x in sys.stdin.readline().split()]
def I(): return int(sys.stdin.readline())
def LS():return [list(x) for x in sys.stdin.readline().split()]
def S():
    res = list(sys.stdin.readline())
    if res[-1] == "\n":
        return res[:-1]
    return res
def IR(n):
    return [I() for i in range(n)]
def LIR(n):
    return [LI() for i in range(n)]
def SR(n):
    return [S() for i in range(n)]
def LSR(n):
    return [LS() for i in range(n)]

sys.setrecursionlimit(1000000)
mod = 1000000007

def solve():
    n,k = LI()
    a = LI()
    l = [math.log(ai) for ai in a]
    s = sum(l[:k])
    for i in range(k,n):
        p = s
        s += l[i]-l[i-k]
        if p < s:
            print("Yes")
        else:
            print("No")

    return


if __name__ == "__main__":
    solve()

Solution (Python):
n,k=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):
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 = tuple(map(int,input().split()))

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

Solution (Python):
import sys

read = sys.stdin.buffer.read
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines

N, K, *A = map(int, read().split())

for x, y in zip(A, A[K:]):
    print('Yes' if x < y else 'No')

Solution (Python):
import sys

n, k, *aaa = map(int, sys.stdin.buffer.read().split())
buf = []
for r in range(k, n):
    l = r - k
    buf.append('Yes' if aaa[l] < aaa[r] else 'No')

print('\n'.join(buf))

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

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

Solution (Python):
def solve():
  N, K = map(int, input().split())
  A = list(map(int, input().split()))
  ans = ['Yes']*(N-K)
  for i in range(N-K):
    if A[i]>=A[i+K]:
      ans[i] = 'No'
  return ans
print(*solve(),sep='\n')

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(a) for a in 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())
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()))

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