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

n = int(input())
a = list(map(int,input().split()))
for i in range(n):
    a[i] = list(format(a[i],'0b').zfill(65))
g = [0 for i in range(65)]
for i in range(65):
    for j in range(n):
        if a[j][i] == '1':
            g[i] += 1
ans = 0
for i in range(len(g)):
    ans += g[i]*(n-g[i])*(pow(2,64-i,10**9+7))
print(ans%(10**9+7))

### FIXED CODE ###

import numpy as np

n = int(input())
arr = np.array([int(i) for i in input().split()])
mod = 10 ** 9 + 7
s = 0

for i in range(60):
    c1 = np.count_nonzero(arr & 1) # 自分がnp.sumを利用したがどうしても正解になれなかった。なぜ？
    s += 2 ** i * c1 * (n - c1)
    arr >>= 1

print(s % mod)
### BUGGY CODE ###

n = int(input())
a_li = list(map(int, input().strip().split()))

a_set = set(a_li)

for i in range(1, n+1):
  if i in a_set:
    print(a_li.count(i))
  else:
      print(0)


### FIXED CODE ###

import sys
input = sys.stdin.readline

def main():
    n = int(input())
    a_li = list(map(int, input().strip().split()))

    a_dict = {}

    for a in a_li:
        if str(a) in a_dict:
            a_dict[str(a)] += 1
        else:
            a_dict[str(a)] = 1

    for i in range(1, n+1):
        if str(i) in a_dict:
            print(a_dict[str(i)])
        else:
            print(0)

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

N = int(input())
s = []
ans = 0
for _ in range(N):
    occurence = {}
    si = input()
    for char in si:
        if char not in occurence:
            occurence[char] = 1
        else:
            occurence[char] += 1
    for previous in s:
        if previous == occurence:
            ans += 1
    s.append(occurence)

print(ans)


### FIXED CODE ###

N = int(input())
dic = {}
ans = 0
for _ in range(N):
    si = input()
    sortedSi = "".join(sorted(si))
    if sortedSi in dic:
        dic[sortedSi] += 1
    else:
        dic[sortedSi] = 1

for val in dic.values():
    ans += val * (val - 1) // 2

print(ans)
### BUGGY CODE ###

N,P=map(int,input().split())
maxfac = int(P**(1/N))
# print(range(1,maxfac+1))
if N==1:
    print(P)
    exit()
for i in range(1,maxfac+2)[::-1]:
    p = i**N
    # print(P%p)
    if P%p == 0:
        print(i)
        break


### FIXED CODE ###

N,P=map(int,input().split())
maxfac = int(P**(1/N))
# print(range(1,maxfac+1))
if N==1:
    print(P)
    exit()
elif N > 10**6:
    print(1)
    exit()
for i in range(1,maxfac+2)[::-1]:
    p = i**N
    # print(P%p)
    if P%p == 0:
        print(i)
        break
### BUGGY CODE ###

N=int(input())
L=list(map(int,input().split()))
M=[0]*N
count=0
while(1):
	for i in range (N-1):
		if L[i]>L[i+1]:
			if M[i]==1:
				print("No")
				exit()
			else:
				L[i]-=1
				M[i]=1
		else:
			count+=1
	if count==(N-1):
		print("Yes")
		exit()


### FIXED CODE ###

N=int(input())
H=list(map(int,input().split()))
M=[0]*N

while(1):
	count=0
	for i in range (N-1):
		if H[i]>H[i+1]:
			if M[i]==1:
				print("No")
				exit()
			else:
				M[i]=1
				H[i]=H[i]-1
		else:
			count+=1
	if count==N-1:
		print("Yes")
		exit()
### BUGGY CODE ###

n,m=map(int, input().split())
a = []
for i in range(m):
    a.append(int(input()))

dp = [0] * (n+1)
dp[0] = 1
if (1 in a):
    dp[1] = 0
else:
    dp[1] = 1

for i in range(2,n+1):
    if (i in a):
        dp[i] = 0
    else:
        dp[i] = (dp[i-1] + dp[i-2])%(10**9+7)

print(dp[n])

### FIXED CODE ###

N, M = map(int, input().split())
a = set([int(input()) for _ in range(M)])
INF = 1000000007

dp = [0] * (N + 1)
dp[0] = 1
if 1 not in a:
	dp[1] = 1
else:
	dp[1] = 0
for i in range(2, N + 1):
	if i in a:
		continue
	dp[i] = dp[i - 1] + dp[i - 2]
	dp[i] %= INF

print(dp[N])
### BUGGY CODE ###

n = int(input())
x = list(map(int, input().split()))
for i in range(n):
    print(sorted(x[:i] + x[i + 1:])[n // 2 - 1])

### FIXED CODE ###

n = int(input())
x = list(map(int, input().split()))
xs = sorted(x)
a = xs[n // 2 - 1]
b = xs[n // 2]
for i in x:
    if i <= a:
        print(b)
    else:
        print(a)
### BUGGY CODE ###

N = int(input())
d = [0] * N
INF = float('inf')

cost = [[INF] * N for i in range(N)]
for _ in range(N - 1):
    a, b, c = map(int, input().split())
    cost[a - 1][b- 1] = c
    cost[b- 1][a - 1] = c
    
def dijkstra(s):
    used = [False] * N
    for i in range(N):
        d[i] = INF
    d[s] = 0
    
    while True:
        v = -1
        for u in range(N):
            if used[u] == False and (v == -1 or d[u] < d[v]):
                v = u
        if v == -1:
            break
        used[v] = True
        
        for u in range(N):
            d[u] = min(d[u], d[v] + cost[v][u])
            
Q, K = map(int, input().split())
for _ in range(Q):
    ans = 0
    x, y = map(int, input().split())
    dijkstra(x - 1)
    ans += d[K - 1]
    #print(d)
    dijkstra(K - 1)
    ans += d[y - 1]
    #print(d)
    print(ans)

### FIXED CODE ###

import heapq

N = int(input())
d = [0] * N
INF = float('inf')

class Info:
    def __init__(self, to, cost):
        self.to = to
        self.cost = cost
        
G = [[] for i in range(N)]
for _ in range(N - 1):
    a, b, c = map(int, input().split())
    G[a - 1].append(Info(b - 1, c))
    G[b - 1].append(Info(a - 1, c))
    
def dijkstra(s):
    for i in range(N):
        d[i] = INF
    d[s] = 0
    h = []
    heapq.heappush(h, [0, s])
    
    while h != []:
        p = heapq.heappop(h)
        v = p[1]
        if d[v] < p[0]:
            continue
        for i in range(len(G[v])):
            e = G[v][i]
            if d[e.to] > d[v] + e.cost:
                d[e.to] = d[v] + e.cost
                heapq.heappush(h, [d[e.to], e.to])

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

dijkstra(K - 1)

for _ in range(Q):
    ans = 0
    x, y = map(int, input().split())
    ans += d[x - 1]
    ans += d[y - 1]
    print(ans)
### BUGGY CODE ###

N=int(input())
S=[]
for _ in range(N):
    s=input()
    S.append("".join(sorted(s)))
    #S.append(sorted(s))
#print(S)
re=0
for i in range(N-1):
    for j in range(i+1,N):
        if S[i]==S[j]:
            re+=1
            #break
print(re)


### FIXED CODE ###

N=int(input())
S=[]
for _ in range(N):
    s=input()
    S.append("".join(sorted(s)))
    #S.append(sorted(s))
#print(S)
re=0
dt={}
for i in range(N):
    if S[i] in dt:
        dt[S[i]]+=1
    else:
        dt[S[i]]=1
for v in dt.values():
    if v>=2:
        v-=1
        re+=(v*(v+1)//2)

print(re)
### BUGGY CODE ###

S = [int(x) if x != '?' else '?' for x in input()]
length = len(S)

A = [0] * 13
B = [0] * 13
mod = 5
first = 0
r = 1

for i in range(length):
    a = S[length - i- 1]
    if a != '?':
        a = (a * r) % 13
        mod -= a
        mod %= 13

    elif first == 0:
        for j in range(10):
            a = (j * r) % 13
            A[a] += 1
        first = 1

    else:
        for j in range(10):
            a = (j * r) % 13
            for k in range(13):
                B[(k + a) % 13] += A[k]
                B[(k + a) % 13] %= 10 ** 9 + 7
        A = B
        B = [0] * 13
    r = (r * 10) % 13

if first == 0 and mod == 0:
    print(1)
elif first == 0 and mod != 0:
    print(0)
else:
    print(A[mod])


### FIXED CODE ###

S = [int(x) if x != '?' else '?' for x in input()]
length = len(S)

A = [0] * 13
B = [0] * 13
mod = 5
first = 0
r = 1

for i in range(length):
    a = S[length - i- 1]
    if a != '?':
        a = (a * r) % 13
        mod -= a
        mod %= 13

    elif first == 0:
        for j in range(10):
            a = (j * r) % 13
            A[a] += 1
        first = 1

    else:
        for j in range(10):
            a = (j * r) % 13
            for k in range(13):
                B[(k + a) % 13] += A[k]
                B[(k + a) % 13] %= 10 ** 9 + 7
        A = B
        B = [0] * 13
    r = (r * 10) % 13

if first == 0 and mod == 0:
    print(1)
elif first == 0 and mod != 0:
    print(0)
else:
    print(A[mod])
### BUGGY CODE ###

import copy

memo = {}
def make_divisors(n):
    if n in memo:
        return memo[n]
    lower_divisors, upper_divisors = [], []
    i = 1
    while i*i <= n:
        if n % i == 0:
            lower_divisors.append(i)
            if i != n // i:
                upper_divisors.append(n//i)
        i += 1
    memo[n] =  lower_divisors + upper_divisors[::-1]
    return memo[n]


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

setA = set(A)
result = 0
for i in range(N):
    divisors = make_divisors(A[i])

    B = copy.copy(A)
    B[i] = 0
    setA = set(B)

    for d in divisors:
        if d in setA:
            break
    else:
        result += 1

print(result)


### FIXED CODE ###

from collections import Counter
N = int(input())
A = list(map(int, input().split()))

sorted_A = sorted(A)
result = 0
c = Counter(sorted_A)
# 倍数を管理するテーブル
lendp = sorted_A[-1] + 1
dp = [0] * lendp

for a in sorted_A:
    dp[a] += 1
    if dp[a] == 1:
        b = a * 2
        while b < lendp:
            dp[b] += 2
            b += a

print(dp.count(1))
### BUGGY CODE ###

import sys
def input():
    return sys.stdin.readline()[:-1]
sys.setrecursionlimit(10**7)
n,q=map(int,input().split())
ab=[list(map(int,input().split())) for i in range(n-1)]
px=[list(map(int,input().split())) for i in range(q)]

def denpan(oya,ko):
    for i in range(len(ne[ko])):
        if ne[ko][i]!=oya:
            cnt[ne[ko][i]]+=cnt[ko]
            denpan(ko,ne[ko][i])

ne=[[] for i in range(n+1)]
for i in range(n-1):
    ne[ab[i][0]].append(ab[i][1])
    ne[ab[i][1]].append(ab[i][0])
# print(ne)
cnt=[0]*(n+1)
for i in range(q):
    cnt[px[i][0]]+=px[i][1]
# print(cnt)
denpan(1,1)
cnt.remove(0)
print(' '.join(map(str,cnt)))

### FIXED CODE ###

import sys
from collections import deque
def input():
    return sys.stdin.readline()[:-1]
sys.setrecursionlimit(10**7)
n,q=map(int,input().split())
ab=[list(map(int,input().split())) for i in range(n-1)]
px=[list(map(int,input().split())) for i in range(q)]

# def denpan(oya,ko):
#     for i in range(len(ne[ko])):
#         if ne[ko][i]!=oya:
#             cnt[ne[ko][i]]+=cnt[ko]
#             denpan(ko,ne[ko][i])

ne=[[] for i in range(n+1)]
for i in range(n-1):
    ne[ab[i][0]].append(ab[i][1])
    ne[ab[i][1]].append(ab[i][0])
# print(ne)
cnt=[0]*(n+1)
for i in range(q):
    cnt[px[i][0]]+=px[i][1]
par=[-1]*(n+1)
stack=deque([1])
while(stack):
    v=stack.pop()
    for i in range(len(ne[v])):
        if ne[v][i]!=par[v]:
            cnt[ne[v][i]]+=cnt[v]
            par[ne[v][i]]=v
            stack.append(ne[v][i])
cnt.remove(0)
print(' '.join(map(str,cnt)))
### BUGGY CODE ###

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

cost=[abs(A[i]-A[i+1]) for i in range(N-1)]

for i in range(N):
  total=sum(cost)+abs(A[0])+abs(A[N-1])
  if i == 0:
    total-=abs(A[i])
    total-=cost[i]
    total+=abs(A[i+1])
  elif i == N-1:
    total-=abs(A[i])
    total+=abs(A[i-1])
    total-=cost[i-1]
  else:
    total-=cost[i]
    total-=cost[i-1]
    total+=abs(A[i+1]-A[i-1])
  print(total)

### FIXED CODE ###

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

cost=[abs(A[i]-A[i+1]) for i in range(N-1)]
costsum=total=sum(cost)+abs(A[0])+abs(A[N-1])
for i in range(N):
  total=costsum
  if i == 0:
    total-=abs(A[i])
    total-=cost[i]
    total+=abs(A[i+1])
  elif i == N-1:
    total-=abs(A[i])
    total+=abs(A[i-1])
    total-=cost[i-1]
  else:
    total-=cost[i]
    total-=cost[i-1]
    total+=abs(A[i+1]-A[i-1])
  print(total)
### BUGGY CODE ###

e,a = map(int,input().split())
cnt = 0
while True:
    if e ==0 and a ==0:
        break
    for i in range(1,a+1):
        for j in range(1,a+1):
            if j<=i:
                continue
            
            X = a - (i + j)
            if X > j and X <=a:
                cnt +=1
print(cnt)


### FIXED CODE ###

while True:
    e,a = map(int,input().split())
    if e ==0 and a ==0:
        break
    cnt = 0
    for i in range(1,e+1):
        for j in range(1,e+1):
            if j<=i:
                continue
            X = a - (i + j)
            if X > j and X <=e:
                cnt +=1
    print(cnt)
### BUGGY CODE ###

N=int(input())

L=[]
for i in range(N):
    L.append([2]*N)

for i in range(N):
    A=int(input())
    for j in range(A):
        x,y=map(int,input().split())
        L[i][x-1]=int(y)

max=0

for i in range(2**N):
    b=list(map(int,list(bin(i))[2:]))
    b=[0]*(N-len(b))+b
    s=0

    for j in range(N):
        for k in range(N):
            if b[j]==1 and b[k]==1:
                if L[j][k]==0 or L[k][j]==0:
                    s=1
            if b[j]==1 and b[k]==0:
                if L[j][k]==1:
                    s=1

    if s==0:
        max=sum(b)

print(max)

### FIXED CODE ###

N=int(input())

L=[]
for i in range(N):
    L.append([2]*N)

for i in range(N):
    A=int(input())
    for j in range(A):
        x,y=map(int,input().split())
        L[i][x-1]=int(y)

max=0

for i in range(2**N):
    b=list(map(int,list(bin(i))[2:]))
    b=[0]*(N-len(b))+b
    s=0

    for j in range(N):
        for k in range(N):
            if b[j]==1 and b[k]==1:
                if L[j][k]==0 or L[k][j]==0:
                    s=1
            if b[j]==1 and b[k]==0:
                if L[j][k]==1:
                    s=1

    if s==0:
        max=sum(b)

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

H, W = map(int, input().split())
S = [0] * H
for i in range(H):
    S[i] = input()

yoko = [[0] * W for i in range(H)]

for i in range(H):
    for j in range(W):
        if yoko[i][j] != 0:
            continue
        elif S[i][j] == "#":
            yoko[i][j] = 0
        else:
            k = 0
            while S[i][j+k] == ".":
                k += 1
                if j+k == W:
                    break
            yoko[i][j:j+k] = [k] * k

tate = [[0] * W for i in range(H)]

for j in range(W):
    for i in range(H):
        if tate[i][j] != 0:
            continue
        elif S[i][j] == "#":
            tate[i][j] = 0
        else:
            k = 0
            while S[i+k][j] == ".":
                k += 1
                if i+k == H:
                    break
            for l in range(k):
                tate[i+l][j] = k

#for i in range(H):
#    print(tate[i])

ans = 0
for i in range(H):
    for j in range(W):
        ans = max(ans, yoko[i][j] + tate[i][j] - 1)

print(ans)

### FIXED CODE ###

H, W = map(int, input().split())
S = [0] * H
for i in range(H):
    S[i] = input()

yoko = [[0] * W for i in range(H)]

for i in range(H):
    for j in range(W):
        if yoko[i][j] != 0:
            continue
        elif S[i][j] == "#":
            yoko[i][j] = 0
        else:
            k = 0
            while S[i][j+k] == ".":
                k += 1
                if j+k == W:
                    break
            yoko[i][j:j+k] = [k] * k

tate = [[0] * W for i in range(H)]

for j in range(W):
    for i in range(H):
        if tate[i][j] != 0:
            continue
        elif S[i][j] == "#":
            tate[i][j] = 0
        else:
            k = 0
            while S[i+k][j] == ".":
                k += 1
                if i+k == H:
                    break
            for l in range(k):
                tate[i+l][j] = k

#for i in range(H):
#    print(tate[i])

ans = 0
for i in range(H):
    for j in range(W):
        ans = max(ans, yoko[i][j] + tate[i][j] - 1)

print(ans)
### BUGGY CODE ###

#C
# 7,77,777･･･=7*(1,11,111･･･)
# 7*(10^i)=7*(10^i-1)/10-1 = 7*(10^i-1)/9 がkで割れる
# 10^iを(9k,7の倍数だったら9k/7)で割ってあまりが１だったら良い
import sys
k=int(input())
if k%7==0:
    k//=7
k*=9
a=10%k
for i in range(k*9):
    a=a%k
    if a==1:
        print(i+1)
        sys.exit()
    a*=10
print(-1)


### FIXED CODE ###

#C
import sys
k=int(input())
s=0

for i in range(k):
    s=s*10+7
    if s%k!=0:
        s=s%k
    else:
        print(i+1)
        sys.exit()
print(-1)
### BUGGY CODE ###

s = input()
k = int(input())
l = len(s)
sub = [s]
for i in range(0,l):
    for j in range(1,l):
        if not s[i:i+j] in sub:
            sub.append(s[i:i+j])
sub.sort()
print(sub[k-1])

### FIXED CODE ###

s = input()
k = int(input())
l = len(s)
sub = set()
for i in range(l):
    for j in range(1,k+1):
        sub.add(s[i:i+j])
print(sorted(sub)[k-1])
### BUGGY CODE ###

import sys
N,M = map(int,input().split())
A = []
B = []
for i in range(N):
    tmp_a,tmp_b = map(int,input().split())
    A.append(tmp_a)
    B.append(tmp_b)
sum_A,sum_B = 0,0
while(M-sum_B)>0:
    min_index = A.index(min(A))
    if (M-sum_B) > B[min_index]:
        sum_A += min(A)*B[min_index]
        sum_B += B[min_index]
        A.pop(min_index)
        B.pop(min_index)
    else:
        sum_A += min(A)*(M-sum_B)
        print(sum_A)
        sys.exit()
        

### FIXED CODE ###

import sys
N,M = map(int,input().split())
List =[]
for i in range(N):
    tmp_a,tmp_b = map(int,input().split())
    List.append([tmp_a,tmp_b])
List.sort()
sum_a,sum_b = 0,0
for i in range(N):
    if M-sum_b > List[i][1]:
        sum_a += List[i][0]*List[i][1]
        sum_b += List[i][1]
    else:
        sum_a += List[i][0]*(M-sum_b)
        sum_b += M-sum_b
        print(sum_a)
        sys.exit()
### BUGGY CODE ###

H, W, M = map(int, input().split())
Hdst = [0]*H
Wdst = [0]*W
DST = [[0] * 2 for i in range(M)]
for i in range(M):
    hi, wi = map(int, input().split())
    Hdst[hi-1] += 1
    Wdst[wi-1] += 1
    DST[i] = [hi-1, wi-1]

Hdstmax = max(Hdst)
Wdstmax = max(Wdst)
Hbomb = [i for i, x in enumerate(Hdst) if x == Hdstmax]
Wbomb = [i for i, x in enumerate(Wdst) if x == Wdstmax]

tmp = M
for i in range(M):
    if (DST[i][0] not in Hbomb) or (DST[i][1] not in Wbomb):
        tmp -= 1

if len(Hbomb)*len(Wbomb) == tmp:
    print(Hdstmax + Wdstmax - 1)
else:
    print(Hdstmax + Wdstmax)


### FIXED CODE ###

H, W, M = map(int, input().split())
Hdst = [0]*H
Wdst = [0]*W
DST = [[0] * M for i in range(2)]
for i in range(M):
    hi, wi = map(int, input().split())
    Hdst[hi-1] += 1
    Wdst[wi-1] += 1
    DST[0][i] = hi-1
    DST[1][i] = wi-1

Hdstmax = max(Hdst)
Wdstmax = max(Wdst)
Hbomb = [i for i, x in enumerate(Hdst) if x == Hdstmax]
Wbomb = [i for i, x in enumerate(Wdst) if x == Wdstmax]

Hchk = [False]*H
Wchk = [False]*W
for i in Hbomb:
    Hchk[i] = True
for i in Wbomb:
    Wchk[i] = True

tmp = 0
for i in range(M):
    if Hchk[DST[0][i]] and Wchk[DST[1][i]]:
        tmp += 1

if len(Hbomb)*len(Wbomb) == tmp:
    print(Hdstmax + Wdstmax - 1)
else:
    print(Hdstmax + Wdstmax)
### BUGGY CODE ###

n=int(input())
a=list(map(int,input().split()))
ans=1
cnt=0
while cnt<n:
  if a[cnt]==0:
    print(0)
    exit()
  ans*=a[cnt]
  cnt+=1
if ans>10**18:
  print(-1)
  exit()
print(ans)

### FIXED CODE ###

n=int(input())
a=list(map(int,input().split()))
ans=1
if 0 in a:
  print(0)
  exit()
for i in a:
  ans*=i
  if ans>10**18:
    print(-1)
    exit()
print(ans)
### BUGGY CODE ###

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

m = -1
index = -1
for i in range(n-k+1):
    tmp = sum(p[i:i+k])
    if tmp > m:
        m = tmp
        index = i


def calc_exp(p):
    num = list(range(1,p+1))
    return sum(num) / p
        
exp = 0
for i in range(index,index+k):
    exp += calc_exp(p[i])

print(exp)


### FIXED CODE ###

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

m = sum(p[:k])
index = 0
tmp = sum(p[:k])
for i in range(n-k):
    tmp -= p[i]
    tmp += p[i+k]
    if tmp > m:
        m = tmp
        index = i+1

def calc_exp(p):
    return ((p * (p+1)) / 2) / p
        
exp = 0
for i in range(index,index+k):
    exp += calc_exp(p[i])

print(exp)
### BUGGY CODE ###


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

x = X[:]
for _ in range(K):
    if all(v == N for v in x):
        break

    new = [0] * N
    for i in range(N):
        for j in range(max(0, i - x[i]), min(N, i + x[i] + 1)):
            new[j] += 1
    x = new[:]

print(*x)


### FIXED CODE ###

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

x = A[:]

for _ in range(min(50, K)):
    y = [0] * (N + 1)
    for i in range(N):
        y[max(0, i - x[i])] += 1
        y[min(N, i + x[i] + 1)] -= 1
        
    for i in range(N):
        y[i + 1] += y[i]
        
    x = y[:]
        
    
print(*x[:-1])
### BUGGY CODE ###

n, q = map(int,input().split())
s = input()
b = []
for t in range(n-1):
	if s[t] == "A" and s[t+1] == "C":
		b.append(t+1)
for u in range(q):
	l, r = map(int, input().split())
	C = []
	if l != r:
		C = [i for i in range(l, r)]
		D = set(b) & set(C)
		print(len(D))

### FIXED CODE ###

n, q = map(int, input().split())
s = input()
b = [0]
for t in range(1, n):
	if s[t-1] == "A" and s[t] == "C":
		b.append(b[t-1] + 1)
	else:
		b.append(b[t-1])
for u in range(q):
	l, r = map(int, input().split())
	print(b[r-1] - b[l-1])
### BUGGY CODE ###

n, k, q = map(int, input().split())
a = [int(input()) for i in range(q)]

point = [k - q] * (n + 1)

for x in range(q):
    for y in range(n) :
        if y + 1 == a[x] :
            point[y] += 1

for z in range(n) :
    if point[z] > 0:
        print("Yes")
    else :
        print("No")

### FIXED CODE ###

n, k, q = map(int, input().split())

point = [k - q] * (n + 1)

for _ in range(q):
    point[int(input()) -1] += 1

for z in range(n) :
    if point[z] > 0:
        print("Yes")
    else :
        print("No")
### BUGGY CODE ###

N = int(input())

partA = list(map(int, input().split()))
partB = list(map(int, input().split()))
partC = list(map(int, input().split()))
counter = 0

for i in range(N):
     for f in range(N):
         if partA[i] < partB[f]:
                for s in range(N):
                    if partB[f] < partC[s]:
                        counter += 1
print(counter)

### FIXED CODE ###

import bisect

def find_lt(a, x):
    i = bisect.bisect_left(a, x)
    if i:
        return i
    return 0

def find_l(a, x):
    i = bisect.bisect_right(a, x)
    if i == 0:
        return len(a)
    else:
        return len(a) - i

def main():
    N = int(input())

    partA = list(map(int, input().split()))
    partA.sort()
    partB = list(map(int, input().split()))
    partB.sort()
    partC = list(map(int, input().split()))
    partC.sort()
    cnt = 0


    for b in partB:
        A = find_lt(partA, b)
        #print (A)
        B = find_l(partC, b)
        #print (B)
        cnt += (A * B)

    print(cnt)

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

from functools import reduce
from fractions import gcd
import math
import bisect
import itertools
import sys
input = sys.stdin.readline
INF = float("inf")


# 処理内容
def main():
    N, K = map(int, input().split())
    A = list(map(int, input().split()))

    score = 1
    for i in range(K):
        score *= A[i]
    
    for i in range(K, N):
        nscore = score * A[i] // A[i-K]
        if nscore > score:
            print("Yes")
        else:
            print("No")
        score = nscore


if __name__ == '__main__':
    main()

### FIXED CODE ###

from functools import reduce
from fractions import gcd
import math
import bisect
import itertools
import sys
input = sys.stdin.readline
INF = float("inf")


# 処理内容
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()
### BUGGY CODE ###

n = int(input())
l = [int(i) for i in input().split()]
ans = 0
for i in range(n-2):
    for j in range(i+1, n-1):
        for k in range(j+1, n):
            if l[i] < l[j] + l[k] and l[j] < l[i] + l[k] and l[k] < l[i] + l[j]: ans += 1
print(ans)

### FIXED CODE ###

from bisect import bisect_left
n = int(input())
l = [int(i) for i in input().split()]
l.sort()
ans = 0
for i in range(n-2):
    for j in range(i+1, n-1):
        ans += bisect_left(l, l[i]+l[j]) - j - 1
print(ans)
### BUGGY CODE ###

N = int(input())
l = list(map(int, input().split()))

count = 1
for i in range(1, N):
  if min(l[:i]) >= l[i]:
    count = count + 1
  else:
    pass
    
print(count)

### FIXED CODE ###

N = int(input())
l = list(map(int, input().split()))

count = 1
min = l[0]
for i in range(1, N):
  if min > l[i]:
    count = count+1
    min = l[i]
    
print(count)