Harryxun/sft_time huggingface dataset:
### BUGGY CODE ###

N, k, Q = map(int, input().split())
A =[]

j = 0
c = 0
 
def calc_de(n):
    return n - 1
 

A = [int(input()) for index in range(Q)]
 
S = [k]*N
 
for j in A:
    S = list(map(calc_de, S))
    S[j-1] += 1
 
for c in range(N):
    if S[c] > 0:
        print('Yes')
    else:
        print('No')

### FIXED CODE ###

N, K, Q = map(int, input().split())

A = [K]*N
C = [0]*N

for r in range(Q):
    correct = int(input())
    C[correct-1] = C[correct-1] + 1

for i in range(N):
    A[i] = A[i] - Q + C[i]
    if A[i] > 0:
        print('Yes')
    else:
        print('No')
### BUGGY CODE ###

import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)
from decimal import Decimal

from heapq import heappush, heappop, heapify
import math
from math import gcd
import itertools as it
import collections
from collections import deque 

def inp():
    return int(input())
def inpl():
    return list(map(int, input().split()))
def _debug(obj):
    print(obj, file=sys.stderr)

# ---------------------------------------

N = inp()
p = [0] + list(map(Decimal, input().split()))
dp = [[0] * (N + 1) for i in range(N + 1)]
dp[0][0] = 1

for i in range(1, N+1):
    for j in range(0, i+1):
        if j > 0:
            dp[i][j] = dp[i-1][j] * (1 - p[i]) + dp[i-1][j-1] * p[i]
        else:
            dp[i][j] = dp[i-1][j] * (1 - p[i])
_debug(dp)
ans = 0
for j in range(N//2 + 1, N + 1):
    ans += dp[N][j]
print(ans)

### FIXED CODE ###

import sys
input = sys.stdin.readline
sys.setrecursionlimit(10**6)
import decimal
from decimal import Decimal
decimal.getcontext().prec = 10

from heapq import heappush, heappop, heapify
import math
from math import gcd
import itertools as it
import collections
from collections import deque 

def inp():
    return int(input())
def inpl():
    return list(map(int, input().split()))
def _debug(obj):
    print(obj, file=sys.stderr)

# ---------------------------------------

N = inp()
p = [0] + list(map(float, input().split()))
dp = [[0] * (N + 1) for i in range(N + 1)]
dp[0][0] = 1

for i in range(1, N+1):
    for j in range(0, i+1):
        if j > 0:
            dp[i][j] = dp[i-1][j] * (1 - p[i]) + dp[i-1][j-1] * p[i]
        else:
            dp[i][j] = dp[i-1][j] * (1 - p[i])
ans = 0
for j in range(N//2 + 1, N + 1):
    ans += dp[N][j]
print(ans)
### BUGGY CODE ###

mod = 10 ** 9 + 7

K = map(int, list(input()))
D = int(input())

s = 0
dp = [0] * D
for k in K:
    T = [0] * D
    for i, dpi in enumerate(dp):
        for x in range(10):
            T[(i + x) % D] += dpi
            T[(i + x) % D] % mod
    for x in range(k):
        T[(s + x) % D] += 1

    s = (s + k) % D
    dp = T

print((dp[0] + (-1 if s != 0 else 0)) % mod)

### FIXED CODE ###

mod = 10 ** 9 + 7

K = input()
D = int(input())

s = 0
dp = [0] * D
for k in K:
    k = int(k)

    T = [0] * D
    for i, dpi in enumerate(dp):
        for x in range(10):
            T[(i + x) % D] = (T[(i + x) % D] + dpi) % mod
    for x in range(k):
        T[(s + x) % D] += 1

    s = (s + k) % D
    dp = T

print((dp[0] + (-1 if s != 0 else 0)) % mod)
### BUGGY CODE ###

import sys
input = sys.stdin.readline

n, x = map(int, input().split())
BLU = [list(map(int, input().split())) for _ in range(n)]
B, L, U = zip(*BLU)
S = [b*l+(x-b)*u for b, l, u in BLU]
sortedS = sorted([(s, i) for i, s in enumerate(S)], reverse=True)
S, idx = zip(*sortedS)
B = [B[i] for i in idx]
L = [L[i] for i in idx]
U = [U[i] for i in idx]
M = sum([b*l for b, l, u in BLU])

def select(q, r):
  f = sum(S[:q+1])
  for i in range(n):
    temp = f - S[min(i, q)]
    temp += L[i]*min(B[i], r) + U[i]*max(r-B[i], 0)
    if temp>=M:
      return True
  return False

ng = -1
ok = sum(B)
while ok-ng > 1:
  mid = (ok+ng)//2
  q, r = divmod(mid, x)
  if select(q, r):
    ok = mid
  else:
    ng = mid
print(ok)

### FIXED CODE ###

"""

重要度はlかuしかとらないと考えてよい
高橋君のほうが青木君より低い点数を取ると決めた科目に対してはl、それ以外はuと定める
それぞれのテストの点数の差をdとして、Σ[a>=b](d*u) - Σ[a<b](d*l) >= 0 を満たす
最小のΣaを求める
→各iについて、biまではli個ずつ減らすことができ、それより多く減らす場合はXを超えない範囲で
 ui個ずつ減らすことができる
→heapqでできそう
 単純なheapqだと、例えば一つのテストの中でlとuの値の差がとても大きい時に
 正しい答えが出せない
→二分探索

"""
import sys
input = sys.stdin.readline

n, x = map(int, input().split())
BLU = [list(map(int, input().split())) for _ in range(n)]
SBLU = sorted([(b*l+(x-b)*u, b, l, u) for b, l, u in BLU], reverse=True)
S, B, L, U = zip(*SBLU)
M = sum([b*l for b, l, u in BLU])

def select(q, r):
  f = sum(S[:q+1])
  for i in range(n):
    temp = f - S[min(i, q)]
    temp += L[i]*min(B[i], r) + U[i]*max(r-B[i], 0)
    if temp>=M:
      return True
  return False


ng = -1
ok = sum(B)
while ok-ng > 1:
  mid = (ok+ng)//2
  q, r = divmod(mid, x)
  if select(q, r):
    ok = mid
  else:
    ng = mid
print(ok)
### BUGGY CODE ###

n = int(input())
dic = []
for i in range(n):
    x = input()
    if 'insert' in x:
        dic.append(x.strip('insert '))
    else :
        if x.strip('find ') in dic:
            print('yes')
        else :
            print('no')



### FIXED CODE ###

n = int(input())
dic = set()
for i in range(n):
    x = input()
    if 'insert' in x:
        dic.add(x.strip('insert '))
    else :
        if x.strip('find ') in dic:
            print('yes')
        else :
            print('no')
### BUGGY CODE ###

A,B,K=map(int,input().split())
for i in range(A,B+1):
    if i<A+K or i>B-K:
        print(i)

### FIXED CODE ###

A,B,K=map(int,input().split())
r=range(A,B+1)
l=list(r[:K]);l.extend(list(r[-K:]))
for i in sorted(set(l)):
    print(i)
### BUGGY CODE ###

import numpy as np
N,M = map(int,input().split())
A = list(map(int,input().split()))
C = np.array(A)
for i in range(M):
  p = np.argmax(C)
  C[p] = int(C[p]/2)
print(sum(C))



### FIXED CODE ###

import numpy as np
import heapq
N,M = map(int,input().split())
A = list(map(int,input().split()))
A = [x*(-1) for x in A]
heapq.heapify(A)
for i in range(M):
  heapq.heapreplace(A,int(A[0]/2))
print(-sum(A))
### BUGGY CODE ###

import sys

def solve():
    input = sys.stdin.readline
    N, T = map(int, input().split())
    food = [[int(i) for i in input().split()] for _ in range(N)]
    food.sort()
    DP = [[0 for _ in range(T)] for i in range(N + 1)]
    for i in range(N):
        a, b = food[i]
        for t in range(T):
            DP[i+1][t] = max(DP[i][t], DP[i+1][t])
            if t+a < T: DP[i+1][t+a] = max(DP[i+1][t+a], DP[i][t] + b)
    max_dish = 0
    for i in range(N):
        max_dish = max(max_dish, max(DP[i]) + food[i][1])
    print(max_dish)

    return 0

if __name__ == "__main__":
    solve()

### FIXED CODE ###

import sys

def solve():
    input = sys.stdin.readline
    N, T = map(int, input().split())
    food = [[int(i) for i in input().split()] for _ in range(N)]
    food.sort()
    DP = [[0 for _ in range(T)] for i in range(N + 1)]
    for i in range(N):
        a, b = food[i]
        for t in range(T):
            DP[i+1][t] = max(DP[i][t], DP[i+1][t])
            if t+a < T: DP[i+1][t+a] = max(DP[i+1][t+a], DP[i][t] + b)
    max_dish = 0
    for i in range(N):
        max_dish = max(max_dish, max(DP[i]) + food[i][1])
    print(max_dish)

    return 0

if __name__ == "__main__":
    solve()
### BUGGY CODE ###

import math
from functools import reduce

k = int(input())
ans = 0

def gcd(*numbers):
    return reduce(math.gcd, numbers)

for i in range(1,k+1):
    for j in range(1,k+1):
        for l in range(1,k+1):
            ans += gcd(i,j,l)
print(ans)

### FIXED CODE ###

import math
k = int(input())

ans = 0

for i in range(1,k+1):
    for j in range(1,k+1):
        a = math.gcd(i, j)
        for l in range(1,k+1):
            ans += math.gcd(a,l)
print(ans)
### BUGGY CODE ###

s = input()
n = len(s)
# 各 B の左にある B の数の和が答え
ans = 0
for i in range(1, n):
    if s[i] == "W":
        ans += s[:i].count("B")
print(ans)

### FIXED CODE ###

# coding: utf-8
S = input()

cnt = 0
ans = 0
for i in range(len(S)):
    if S[i]=="B":
        cnt+=1
    else:
        ans += cnt
        cnt += 0
print(ans)
### BUGGY CODE ###

import math

bl=input().split()
A=int(bl[0])
B=int(bl[1])
C=int(bl[2])
m=0
for x in range(C+1):
  y=math.floor(A*x/B)-A*math.floor(x/B)
  if y>m:
    m=y
print(m)

### FIXED CODE ###

import math

bl=input().split()
A=int(bl[0])
B=int(bl[1])
C=int(bl[2])

if C<B:
  m=math.floor(A*C/B)-A*math.floor(C/B)
else:
  m=math.floor(A*(B-1)/B)

print(m)
### BUGGY CODE ###

from collections import deque
N, M = map(int, input().split())
left = deque([])
right = deque([])
for i in range(M):
  a, b = map(int, input().split())
  if a == 1:
    left.append(b)
  elif b == N:
    right.append(a)
    
flag = False
for r in right:
  if r in left:
    flag = True
    break
    
if flag:
  print('POSSIBLE')
else:
  print('IMPOSSIBLE')

### FIXED CODE ###

N, M = map(int, input().split())
left = []
right = []
for i in range(M):
  a, b = map(int, input().split())
  if a == 1:
    left.append(b)
  elif b == N:
    right.append(a)
    
flag = False
left = set(left)
for r in right:
  if r in left:
    flag = True
    break
    
if flag:
  print('POSSIBLE')
else:
  print('IMPOSSIBLE')
### BUGGY CODE ###

import sys
def input():
    return sys.stdin.readline()[:-1]

from itertools import count
def test():
    n = int(input())
    a = [int(i) for i in input().split()]
    r = [True for i in range(1, n+1) if all([a[i-1] % a[j-1] != 0 for j in range(1, n+1) if i != j])]
    print(len([i for i in r if i]))

test()

### FIXED CODE ###

import sys
def input():
    return sys.stdin.readline()[:-1]

from itertools import count
from collections import Counter

def test():
    n = int(input())
    a = sorted([int(i) for i in input().split()])
    mxn = a[-1]
    c = Counter(a)
    a = sorted(list(set(a)))
    r = dict()
    for i in a:
        for j in count(1):
            if i * j > mxn: break
            r[i * j] = r.get(i * j, 0) + 1
    print(len([k for k in a if r[k] == 1 and c[k] == 1]))


test()
### BUGGY CODE ###

import itertools
import functools
import operator

N, K = [int(x) for x in input().split()]

arr = [int(x) for x in input().split()]

#print(arr)

mx_list = []

for x in itertools.combinations(arr, K):
    #print(x)
    mx_list.append(functools.reduce(operator.mul,x))

mx = max(mx_list)

y = (10**9 + 7)

print(mx % y)

### FIXED CODE ###

mod=10**9+7
n,k=map(int,input().split())
arr=list(map(int,input().split()))
cnt_plus=0
cnt_zero=0
cnt_minus=0
arr_plus=[]
arr_minus=[]

for i in range(n):
    if arr[i]>0:
        cnt_plus+=1
        arr_plus.append(arr[i])
    elif arr[i]<0:
        cnt_minus+=1
        arr_minus.append(-arr[i])
    else:
        cnt_zero+=1
if cnt_plus+cnt_minus<k: #K個の積の中に0を含む場合、答えは0
    print(0)
    exit()
    
if k==n: #K=Nの場合
    if cnt_zero!=0: #0がひとつでもあれば答えは0
        print(0)
    else:
        ans=1
        for i in range(cnt_plus):
            ans*=arr_plus[i]
            ans%=mod
        for i in range(cnt_minus):
            ans*=arr_minus[i]
            ans%=mod
        if cnt_minus%2==0: #負の数が偶数個であれば積は正
            print(ans)
        else: #そうでなければ積は負となる
            print((-ans)%mod)
    exit()
if cnt_plus==0 and k%2==1: #正の数がないとき
    if cnt_zero!=0: #0がひとつでもあれば答えは0にできる
        print(0)
    else: #0がないときは負の数を絶対値が小さい順に掛けるのが最善
        arr_minus=sorted(arr_minus)
        tmp=1
        for i in range(k):
            tmp*=arr_minus[i]
            tmp%=mod
        print((-tmp)%mod)
    exit()
else: #正の数と負の数から合計K個取れるとき
    arr_plus=sorted(arr_plus,reverse=True)
    arr_minus=sorted(arr_minus,reverse=True)
    if k%2==0: #Kが偶数であれば何もしない
        ans=1
        pos_plus=0
        pos_minus=0
        cnt=0
    else: #Kが奇数であれば正の数から最大のものを取っておき、Kが偶数の場合に帰着させる
        ans=arr_plus[0]
        pos_plus=1
        pos_minus=0
        cnt=1
    while cnt<k:
        cand1=0
        if pos_plus<=cnt_plus-2: #正の数を2つ取れるなら取る
            cand1=arr_plus[pos_plus]*arr_plus[pos_plus+1]      
            cand2=0
        if pos_minus<=cnt_minus-2: #負の数を2つ取れるなら取る:
            cand2=arr_minus[pos_minus]*arr_minus[pos_minus+1]
        if cand1>=cand2: #正の数を2つ取った積のほうが大きい場合
            pos_plus+=2
            ans*=cand1
            ans%=mod
        else: #負の数を2つ取った積のほうが大きい場合
            pos_minus+=2
            ans*=cand2
            ans%=mod
        cnt+=2
    print(ans)
    exit()
### BUGGY CODE ###

number = int(input())
lower = list(map(int, input().split()))

time = 0
max = 0

def down(i):
    global time
    for j in range(i, number-1):
        if lower[j] >= lower[j+1]:
            time += 1
        else:
            return


for i in range(len(lower)):
    down(i)
    if max < time:
        max = time
    time = 0

print(max)


### FIXED CODE ###

number = int(input())
lower = list(map(int, input().split()))

time = 0
max = 0

def down(i):
    global time
    for j in range(i, number-1):
        if lower[j] >= lower[j+1]:
            time += 1
        else:
            return j+1

    return 0

now = 0
for i in range(len(lower)):

    if now > i:
        continue

    if max > (number-i+1):
        break

    now = down(i)

    if max < time:
        max = time
    time = 0



print(max)
### BUGGY CODE ###

n = int(input())

a = list(map(int, input().split()))
a = sorted(a, reverse=True)
comfort = a[0:2]
sum = max(a[0], a[1])
for j in a[2:]:
    key = 0
    for i in range(len(comfort) - 1):
        comfort_value = min(comfort[1], comfort[-1])
        comfort_value_kari = min(comfort[i], comfort[i + 1])
        if comfort_value < comfort_value_kari:
            comfort_value = comfort_value_kari
            key = i
    comfort.insert(key, j)
    sum += comfort_value
print(sum)



### FIXED CODE ###

import heapq
n = int(input())

arr = list(map(int, input().split()))
arr = sorted(arr, reverse=True)
ans = 0
q = []
heapq.heappush(q, -arr[0])
for i in range(1, n):
    tmp = heapq.heappop(q)
    tmp *= -1
    ans += tmp
    heapq.heappush(q, -arr[i])
    heapq.heappush(q, -arr[i])
print(ans)
### BUGGY CODE ###

n = int(input())

a = []
s = [0] * n
a.append(input().split())

for i in range(n - 1):
    a[0][i] = int(a[0][i])
    for j in range(a[0][i]+1):
        if j == a[0][i]:
            s[j - 1] += 1
            break

for i in range(n):
    print(s[i])

### FIXED CODE ###

n = int(input())

a = []
s = [0] * n
a.append(input().split())

for i in range(n - 1):
    a[0][i] = int(a[0][i])
    s[a[0][i]-1] += 1

for i in range(n):
    print(s[i])
### BUGGY CODE ###

a, b, n= [int(i) for i in input().split()]

max = 0

for i in range(n+1):
  x = int((a*i)/b)-a*int(i/b)
  if x > max:
    max = x
  elif max > x:
    break
    
print(max)

### FIXED CODE ###

a, b, n= [int(i) for i in input().split()]

if int(n/b) == 0:
  print(int((a*n)/b))
else:
  print(int((a*(b-1))/b))
### BUGGY CODE ###

import sys

input = sys.stdin.readline

def main(): 
    N = int(input())
    A = [0] + list(map(int, input().split()))
    
    ans = [0] * (N+1)
    c = 0
    for i in range(N, 0, -1):
        t = 0
        for j in range(2*i, N+1):
            t += ans[j]
            
        if A[i] != (t%2): 
            ans[i] = 1
            c += 1
            
    print(c)
    print('1 '*c)

if __name__ == '__main__':
    main()

### FIXED CODE ###

N = int(input())
a = [0] + list(map(int, input().split()))
b = [0] * (N+1)

for i in range(N, 0, -1):
    mod = sum(b[i::i]) % 2
    if mod == a[i]:
        pass
    else:
        b[i] = 1
    
print(b.count(1))
for idx, n in enumerate(b):
    if n:
        print(idx, '', end='')
### BUGGY CODE ###

n, m, k = map(int, input().split())
mod = 998244353
def powerDX(n, r, mod):
  if r == 0: return 1
  if r%2 == 0:
    return powerDX(n*n % mod, r//2, mod) % mod
  if r%2 == 1:
    return n * powerDX(n, r-1, mod) % mod
 
def combination(n, r, mod):
    n1, r = n+1, min(r, n-r)
    numer = denom = 1
    for i in range(1, r+1):
        numer = numer * (n1-i) % mod
        denom = denom * i % mod
    return numer * powerDX(denom, mod-2, mod) % mod
 
ans = 0
for i in range(0, k+1):
  ans += m*combination(n-1, i, mod)*powerDX(m-1, n-i-1, mod)
  ans %= mod
print(ans)

### FIXED CODE ###

n, m, k = map(int, input().split())
mod = 998244353

def powerDX(n, r, mod):
  if r == 0: return 1
  if r%2 == 0:
    return powerDX(n*n % mod, r//2, mod) % mod
  if r%2 == 1:
    return n * powerDX(n, r-1, mod) % mod

def cmb(n, r, mod):
    if ( r<0 or r>n ):
        return 0
    r = min(r, n-r)
    return g1[n] * g2[r] * g2[n-r] % mod
 
g1 = [1, 1]
g2 = [1, 1]
inverse = [0, 1]
 
for i in range(2, n + 1 ):
    g1.append( ( g1[-1] * i ) % mod )
    inverse.append( ( -inverse[mod % i] * (mod//i) ) % mod )
    g2.append( (g2[-1] * inverse[-1]) % mod )

ans = 0
for i in range(0, k+1):
  ans += m*cmb(n-1, i, mod)*powerDX(m-1, n-i-1, mod)
  ans %= mod
print(ans)
### BUGGY CODE ###

import math
import itertools
import heapq
from sys import stdin, stdout, setrecursionlimit
from bisect import bisect, bisect_left, bisect_right
from collections import defaultdict, deque


# d = defaultdict(lambda: 0)
# setrecursionlimit(10**7)
# inf = float("inf")


##### stdin ####
def LM(t, r): return list(map(t, r))
def R(): return stdin.readline()
def RS(): return R().split()
def I(): return int(R())
def F(): return float(R())
def LI(): return LM(int,RS())
def LF(): return LM(float,RS())
def ONE_SL(): return list(input())
def ONE_IL(): return LM(int, ONE_SL())
def ALL_I(): return map(int, stdin)
def ALL_IL(): return LM(int,stdin)

##### tools #####
def ap(f): return f.append
def pll(li): print('\n'.join(LM(str,li)))
def pljoin(li, s): print(s.join(li))



##### main #####		
def main():
	N,K = LI()
	A = LI()
	set_A = set(A)
	d = {}
	for a in set_A:
		d[a] = A.count(a)

	ans=0
	while len(d)>K:
		min_v,min_k = min((v,k) for (k,v) in d.items())
		max_v,max_k = max((v,k) for (k,v) in d.items())
		d[max_k] += min_v
		ans += min_v
		del d[min_k]

	print(ans)


if __name__ == '__main__':
	main()

### FIXED CODE ###

import math
import itertools
import heapq
from sys import stdin, stdout, setrecursionlimit
from bisect import bisect, bisect_left, bisect_right
from collections import defaultdict, deque


# d = defaultdict(lambda: 0)
# setrecursionlimit(10**7)
# inf = float("inf")


##### stdin ####
def LM(t, r): return list(map(t, r))
def R(): return stdin.readline()
def RS(): return R().split()
def I(): return int(R())
def F(): return float(R())
def LI(): return LM(int,RS())
def LF(): return LM(float,RS())
def ONE_SL(): return list(input())
def ONE_IL(): return LM(int, ONE_SL())
def ALL_I(): return map(int, stdin)
def ALL_IL(): return LM(int,stdin)

##### tools #####
def ap(f): return f.append
def pll(li): print('\n'.join(LM(str,li)))
def pljoin(li, s): print(s.join(li))



##### main #####		
def main():
	N,K = LI()
	A = LI()

	cnt_d=defaultdict(lambda: 0)
	for i in A:
		cnt_d[i] += 1
	
	sorted_d = sorted(cnt_d.items(), key=lambda x: x[1])
	
	ans=0
	i=0
	n = len(cnt_d)
	while n>K:
		min_k,min_v = sorted_d[i]
		i+=1
		ans+=min_v
		n-=1

	print(ans)


if __name__ == '__main__':
	main()
### BUGGY CODE ###

h,w,m=map(int,input().split())
A=[0]*h ; B=[0]*w ;G=[]
for i in range(m):
    x,y=map(int,input().split())
    A[x-1]+=1 ; B[y-1]+=1
    G.append([x-1,y-1])

q=max(A) ; e=max(B)
Q=[i for i in range(h) if A[i]==q] 
W=[j for j in range(w) if B[j]==e];#print(A,B,Q,W)
grid={}
for i in Q:
    for j in W:
        grid[ (i,j) ]=0



for i in range(m):
    x,y=G[i]
    if A[x]==q and B[y]==e:
        grid[(x,y)]=1
#print(grid)
if 0 in grid.values():
    print(q+e)
else:
    print(q+e-1)

### FIXED CODE ###

h,w,m=map(int,input().split())
A=[0]*h ; B=[0]*w ;G=[]
for i in range(m):
    x,y=map(int,input().split())
    A[x-1]+=1 ; B[y-1]+=1
    G.append([x-1,y-1])

q=max(A) ; e=max(B)
Q=[i for i in range(h) if A[i]==q] 
W=[j for j in range(w) if B[j]==e];#print(A,B,Q,W)
cnt=len(Q)*len(W)



for i in range(m):
    x,y=G[i]
    if A[x]==q and B[y]==e:
        cnt-=1
#print(grid)
if cnt==0:
    print(q+e-1)
else:
    print(q+e)
### BUGGY CODE ###

n = int(input())
print(sum([i for i in range(1, n)]))

### FIXED CODE ###

n = int(input())
print("%d"%((n-1)*n//2))
### BUGGY CODE ###

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 CODE ###

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 CODE ###

import random

def calc_score(D, C, S, T):
    score = 0
    last = [0]*26
    for d in range(D):
        t = T[d] - 1
        score += S[d][t]
        last[t] = d + 1
        for i in range(26):
            score -= C[i]*(d + 1 - last[i])
    return score

def main():
    D = int(input())
    C = list(map(int, input().split()))
    S = []
    for i in range(D):
        S.append(list(map(int, input().split())))

    last = [0]*26
    ans = []
    for d in range(D):
        score = -100*365
        t = 0
        for i in range(26):
            tmp = S[d][i]
            for j in range(26):
                if i != j:
                    tmp -= C[j]*(d + 1 - last[j])
            if tmp > score:
                score = tmp
                t = i + 1
        last[t - 1] = d + 1
        ans.append(t)
    score = calc_score(D, C, S, ans)
    for i in range(10**4):
        d = random.randint(0, D - 1)
        t = random.randint(0, 25)
        org_t = ans[d]
        ans[d] = t
        s = calc_score(D, C, S, ans)
        if s <= score:
            ans[d] = org_t
        else:
            score = s
    print('\n'.join(map(str, ans)))

if __name__ == '__main__':
    main()


### FIXED CODE ###

def main():
    D = int(input())
    C = list(map(int, input().split()))
    S = []
    for i in range(D):
        S.append(list(map(int, input().split())))

    last = [0]*26
    ans = []
    for d in range(D):
        s = 0
        t = 0
        for i in range(26):
            tmp = S[d][i]
            if tmp > s:
                s = tmp
                t = i + 1
        ans.append(t)
    print('\n'.join(map(str, ans)))

if __name__ == '__main__':
    main()
### BUGGY CODE ###

n,m=map(int,input().split())
if abs(n-m)>1: print(0)
else:
    mod=10**9+7
    def fact(n):
        ans=1
        for i in range(n):
            ans*=(i+1)
        return ans%mod

    ans=(fact(n)*fact(m))%mod
    if n==m: print((2*ans)%mod)
    else: print(ans)

### FIXED CODE ###

n,m=map(int,input().split())
if abs(n-m)>1: print(0)
else:
    mod=10**9+7
    def fact(n):
        ans=1
        for i in range(n):
            ans*=(i+1)
            ans%=mod
        return ans

    ans=(fact(n)*fact(m))%mod
    if n==m: print((2*ans)%mod)
    else: print(ans)
### BUGGY CODE ###

def typical_stairs(n, m, ali):

    mod = 10**9+7

    dp = [0]*(n+1)
    dp[0] = 1

    for i in range(1, n+1):
        if i in ali:
            continue
        dp[i] = dp[i-2] + dp[i-1]

    return dp[i]%mod

def main():
    n, m = map(int, input().split())
    ali = [int(input())for i in range(m)]
    print(typical_stairs(n, m, ali))

if __name__ == '__main__':
    main()

### FIXED CODE ###

def typical_stairs(n, m, ali):

    mod = 10**9+7
    flag = [True]*(n+1)
    for i in ali:
        flag[i] = False

    dp = [0]*(n+1)
    dp[0] = 1

    for i in range(1, n+1):
        if not flag[i]:
            continue
        dp[i] = dp[i-2] + dp[i-1]
        dp[i] %= mod

    return dp[i]

def main():
    n, m = map(int, input().split())
    ali = [int(input())for i in range(m)]
    print(typical_stairs(n, m, ali))

if __name__ == '__main__':
    main()
### BUGGY CODE ###

s = input().split()
n=int(s[0])
x=int(s[1])-1
y=int(s[2])-1
inf=float('inf')
map=[]
for i in range(n):
    for j in range(i+1,n):
        map.append(min(abs(j-i),abs(x-i)+1+abs(j-y),abs(y-i)+1+abs(j-x)))
for i in range(1,n):
    print(map.count(i))

### FIXED CODE ###

s = input().split()
n=int(s[0])
x=int(s[1])-1
y=int(s[2])-1
inf=float('inf')
map={}
for i in range(n):
    map[i]=0
for i in range(n):
    for j in range(i+1,n):
        map[min(abs(j-i),abs(x-i)+1+abs(j-y),abs(y-i)+1+abs(j-x))]+=1
for i in range(1,n):
    print(map[i])