Buggy python submission (verdict: Time Limit Exceeded):
N,K = map(int, input().split())
A = list(map(int, input().split()))
i = N - K
while i > 0:
    print('Yes' if A[K] > A[0] else 'No')
    A.pop(0)
    i -= 1

Fixed submission:
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')

Buggy python submission (verdict: Time Limit Exceeded):
N,K = map(int, input().split())
A = list(map(int, input().split()))
while True:
    print('Yes' if A[K] > A[0] else 'No')
    A.pop(0)
    if len(A) == K:
        break

Fixed submission:
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')

Buggy python submission (verdict: Time Limit Exceeded):
from functools import reduce
N,K = map(int, input().split())
A = list(map(int, input().split()))
M = reduce((lambda X,Y: X*Y), A[:K])
while True:
    A.pop(0)
    if len(A) == K - 1:
        break
    P = reduce((lambda X,Y: X*Y), A[:K])
    print('Yes' if P > M else 'No')
    M = P

Fixed submission:
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')

Buggy python submission (verdict: Time Limit Exceeded):
N,K = map(int, input().split())
A = list(map(int, input().split()))
M = 1
for i in range (K):
    M *= A[i]
while True:
    A.pop(0)
    if len(A) == K - 1:
        break
    P = 1
    for i in range (K):
    	P *= A[i]
    print('Yes' if P > M else 'No')
    M = P

Fixed submission:
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')

Buggy python submission (verdict: Time Limit Exceeded):
N,K = map(int, input().split())
A = list(map(int, input().split()))
def prod(X,Y):
    Z = 0
    while Y > 0:
        if Y % 2 == 1:
            Z += X
        X <<= 1
        Y >>= 1
    return Z 
M = 1
for i in range (0,K):
    M = prod(M, A[i])
while True:
    def prod(X,Y):
        Z = 0
        while Y > 0:
            if Y % 2 == 1:
                Z += X
            X <<= 1
            Y >>= 1
        return Z 
    A.pop(0)
    if len(A) == K - 1:
        break
    P = 1
    for i in range (K):
        P = prod(P, A[i])
    print('Yes' if P > M else 'No')
    M = P

Fixed submission:
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')

Buggy python submission (verdict: Time Limit Exceeded):
N,K = map(int, input().split())
A = list(map(int, input().split()))
M = 1
for i in range (0,K):
    M *= A[i]
while True:
    A.pop(0)
    if len(A) == K - 1:
        break
    P = 1
    for i in range (0,K):
        P *= A[i]
        if P > M:
            break
    print('Yes' if P > M else 'No')
    M = P
        


Fixed submission:
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')

Buggy python submission (verdict: Time Limit Exceeded):
from math import prod
N,K = map(int, input().split())
A = list(map(int, input().split()))
M = prod(A[:K])
while True:
    A.pop(0)
    if len(A) == K - 1:
        break
    P = prod(A[:K])
    print('Yes' if P > M else 'No')
    M = P

Fixed submission:
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')