Problem:


Score: 300 points

Problem Statement

Takahashi has decided to hold fastest-finger-fast quiz games. Kizahashi, who is in charge of making the scoreboard, is struggling to write the program that manages the players' scores in a game, which proceeds as follows.

A game is played by N players, numbered 1 to N. At the beginning of a game, each player has K points.

When a player correctly answers a question, each of the other N-1 players receives minus one (-1) point. There is no other factor that affects the players' scores.

At the end of a game, the players with 0 points or lower are eliminated, and the remaining players survive.

In the last game, the players gave a total of Q correct answers, the i-th of which was given by Player A_i.
For Kizahashi, write a program that determines whether each of the N players survived this game.

Constraints

All values in input are integers.

2 \leq N \leq 10^5

1 \leq K \leq 10^9

1 \leq Q \leq 10^5

1 \leq A_i \leq N\ (1 \leq i \leq Q)

Input

Input is given from Standard Input in the following format:

N K Q
A_1
A_2
.
.
.
A_Q

Output

Print N lines. The i-th line should contain Yes if Player i survived the game, and No otherwise.

Sample Input 1

6 3 4
3
1
3
2

Sample Output 1

No
No
Yes
No
No
No

In the beginning, the players' scores are (3, 3, 3, 3, 3, 3).

Player 3 correctly answers a question. The players' scores are now (2, 2, 3, 2, 2, 2).

Player 1 correctly answers a question. The players' scores are now (2, 1, 2, 1, 1, 1).

Player 3 correctly answers a question. The players' scores are now (1, 0, 2, 0, 0, 0).

Player 2 correctly answers a question. The players' scores are now (0, 0, 1, -1, -1, -1).

Players 1, 2, 4, 5 and 6, who have 0 points or lower, are eliminated, and Player 3 survives this game.

Sample Input 2

6 5 4
3
1
3
2

Sample Output 2

Yes
Yes
Yes
Yes
Yes
Yes

Sample Input 3

10 13 15
3
1
4
1
5
9
2
6
5
3
5
8
9
7
9

Sample Output 3

No
No
No
No
Yes
No
No
No
Yes
No



Sample input:
6 3 4
3
1
3
2


Sample output:
No
No
Yes
No
No
No

Submission status: Accepted

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

p = [k - q] * n

for i in range(q):
    p[int(a[i]) - 1] += 1

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

Submission status: Accepted

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

count = [k - q] * n
for i in a:
    count[i-1] += 1

for i in range(n):
    if count[i] <= 0:
        print("No")
    else:
        print("Yes")

Submission status: Accepted

Solution code:
N, K, Q = map(int,input().split())
A = [0]*Q
survive = [0]*N

for i in range (Q):
    A[i] = int(input())

result={}
for i in range (0,len(A)):
    item = A[i]
    if item in result:
        result[item] = result[item]+1
    else:
        result[item] = 1

for i in range (1,N+1):
    item = i
    if item not in result:
        result[item] = 0

result_sort = sorted(result.items())

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

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
# 整数の入力
# N = int(input())
N, K, Q = map(int, input().split())
aList = [int(input()) for i in range(Q)]
# スペース区切りの整数の入力
# b, c = map(int, input().split())
# 文字列の入力
#s = input()
# sList=[input() for i in range(N)]
scoreList = [0] * N;
for i in range(len(aList)):
  seikaisya = aList[i];
  scoreList[seikaisya - 1] = scoreList[seikaisya - 1] + 1;

# 出力
for i in range(len(scoreList)):
  if K - Q + scoreList[i] > 0:
    print('Yes');
  else:
    print('No');

Submission status: Accepted

Solution code:
n,k,q=map(int,input().split())
a=[]
[a.append(int(input())-1) for _ in range(q)]
i=[k-q]*n

for l in range(q):
    i[a[l]] += 1

for l in range(n):
    if i[l] <= 0:
        print("No")
    else:
        print("Yes")

Submission status: Accepted

Solution code:
N,K,Q=map(int,input().split())
point=[K]*N
for i in range(Q):
  A=int(input())
  A=A-1
  point[A]+=1
for j in range(N):
  if point[j]>Q:
    print("Yes")
  else:
    print("No")

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
res = [k - q] * n
for _ in range(q):
    c = int(input())
    res[c-1] += 1
for i in range(n):
    if res[i] <= 0:
        print("No")
    else:
        print("Yes")
#print(res)

Submission status: Accepted

Solution code:
N, K, Q = [int(_) for _ in input().split()]

A = []
for _ in range(Q):
  A.append(int(input()) - 1)

score = [K - Q] * N

for i in range(len(A)):
  score[A[i]] += 1

for i in range(len(score)):
  if score[i] <= 0:
    print("No")
  else:
    print("Yes")

Submission status: Accepted

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

point = [K-Q] * N

for i in range(Q):
    A = int(input())
    point[A-1] += 1

for i in range(N):
    print(['No', 'Yes'][point[i] > 0])

Submission status: Accepted

Solution code:
n,k,q = map(int, input().split())
a=[int(input()) for _ in range(q)]
b=[0]*n#正解数
init=[k]*n #最初の点数
c=[q]*n#問題数
d=[0]*n#結果

for i in range(q):
    b[a[i]-1] += 1

for i in range(n):
    d[i] = init[i]-c[i]+b[i]

# print(d)
for i in range(len(d)):
    print('Yes' if d[i]>0 else 'No')

Submission status: Accepted

Solution code:
n,k,q=map(int,input().split())
l=[]
for i in range(n):
  v=[i,0]
  l.append(v)
for j in range(q):
  p=int(input())
  l[p-1][1]+=1
for m in range(n):
  if l[m][1]>q-k:
    print('Yes')
  else:
    print('No')

Submission status: Accepted

Solution code:
n,k,q = map(int,input().split())
respondent_lst = [int(input()) for _ in range(q)]
point_lst = [k-q]*n

for i in range(q):
    respondent = respondent_lst[i]
    point_lst[respondent-1] += 1

for i in range(n):
    point = point_lst[i]
    if point>0:
        print('Yes')
    else:
        print('No')

Submission status: Accepted

Solution code:
N, K, Q = map(int,input().split())
A = [int((input())) for i in range(Q)]
pt = [K for i in range(N)]

import collections
ct = collections.Counter(A)

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

Submission status: Accepted

Solution code:
N, K, Q = map(int, input().split())
A = list(int(input()) for _ in range(Q))

score = [0] * N
for i in range(Q):
  score[A[i] - 1] += 1
 
ans = []
for j in range(N):
  if K - Q + score[j] <= 0:
    ans.append("No")
  else:
    ans.append("Yes")
 
for a in ans:
  print(a)

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
arr = [int(input())-1 for i in range(q)]
scores = [k - q] * n
for v in arr:
    scores[v] += 1
for score in scores:
    if score > 0:
        print('Yes')
    else:
        print('No')

Submission status: Accepted

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

Submission status: Accepted

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

A = []
R = [K - Q] * N
for _ in range(Q):
    a = int(input()) - 1
    R[a] += 1

for rr in R:
    print('Yes' if rr > 0 else 'No')

Submission status: Accepted

Solution code:
N,K,Q=map(int,input().split())
A=[]
for i in range(0,Q):
    A.append(int(input()))
Ans=[0]*N
for a in A:
    Ans[a-1]+=1
for i in range(0, N):
    if K-Q+Ans[i]>0:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
import sys

sys.setrecursionlimit(10 ** 6)
int1 = lambda x: int(x) - 1
p2D = lambda x: print(*x, sep="\n")
def IS(): return sys.stdin.readline()[:-1]
def II(): return int(sys.stdin.readline())
def MI(): return map(int, sys.stdin.readline().split())
def LI(): return list(map(int, sys.stdin.readline().split()))
def LI1(): return list(map(int1, sys.stdin.readline().split()))
def LII(rows_number): return [II() for _ in range(rows_number)]
def LLI(rows_number): return [LI() for _ in range(rows_number)]
def LLI1(rows_number): return [LI1() for _ in range(rows_number)]

def main():
	N,K,Q = MI()
	cnt = [0]*N
	for i in range(Q):
		A = II()
		cnt[A-1]+=1
	ans = 0
	for i in range(N):
		if(K-Q+cnt[i] > 0):
			print("Yes")
		else:
			print("No")


main()

Submission status: Accepted

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

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

for i in a:
  b[i] += 1

for i in range(1, len(b)):
  if b[i] > 0:
    print('Yes')
  else:
    print('No')

Submission status: Accepted

Solution code:
N,K,Q=map(int,input().split())
hito=[]
points=[]
for _ in range(Q):
    hito.append(int(input()))
for _ in range(N):
    points.append(K-Q)
for i in hito:
    points[i-1]+=1
for j in points:
    if j>0:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
n,k,q = map(int,input().split())
p_lis = [k-q] * n

for i in range(q):
    x = int(input())
    p_lis[x-1] += 1
for j in p_lis:
    if j > 0:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
point = [k-q for _ in range(n)]
 
for i in range(q):
    a = int(input())
    point[a-1] = point[a-1] + 1
 
ans = '\n'.join('Yes' if i > 0 else 'No' for i in point[0:])
print(ans)

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
point = [k-q] * n

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

ans = '\n'.join('Yes' if i > 0 else 'No' for i in point[0:])
print(ans)

Submission status: Accepted

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

pointl=[k-q for i in range(n)]

for i in range(q):
    a=int(input())
    pointl[a-1]=pointl[a-1]+1

for i in range(n):
    if pointl[i]<=0:
        print("No")
    else:
        print("Yes")

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 4, Feb, 2020
"""

import sys

# import numpy as np

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

N, K, Q, *A = map(int, read().split())
point = [K - Q] * (N + 1)

for i in A:
    point[i] += 1
ans = '\n'.join('Yes' if i > 0 else 'No' for i in point[1:])
print(ans)

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 4, Feb, 2020
"""

import sys
# import numpy as np

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

N, K, Q, *A = map(int, read().split())
point =[K-Q]*(N+1)

for i in A:
    point[i] += 1
print(*['Yes' if i > 0 else 'No' for i in point[1:]], sep='\n')

Submission status: Accepted

Solution code:
"""
author : halo2halo
date : 4, Feb, 2020
"""

import sys
import numpy as np

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

N, K, Q, *A = map(int, read().split())
point = np.zeros(N+1)

for i in A:
    point[i] += 1
point += K - Q
print(*['Yes' if i > 0 else 'No' for i in point[1:]], sep='\n')

Submission status: Accepted

Solution code:
N,K,Q=map(int,input().split())
A=[]
ans=[]
re_ans=""
for i in range(Q):
    A.append(int(input()))
while N>0:
    ans.append(K)
    N-=1
for j in A:
    ans[j-1]=ans[j-1]+1
for k in ans:
    if k-len(A)>0:
        re_ans+="Yes\n"
    else:
        re_ans+="No\n"
print(re_ans.rstrip("\n"))

Submission status: Accepted

Solution code:
n,k,q=list(map(int,input().split()))
a=[int(input()) for _ in range(q)]
c=q-k
if c<0:
    for _ in range(n):
        print("Yes")

    exit()
cal=[0 for _ in range(n)]
for i in a:
    cal[i-1]+=1
for i in range(n):
    if cal[i]>c:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
N,K,Q = map(int,input().split())
A=[0]*Q
for i in range(Q):
    A[i]=int(input())

sanka=[0]*N
for i in range(Q):
    sanka[A[i]-1] +=1

for j in range(N):
    sanka[j]=sanka[j]+K-Q

for k in range(N):
    if sanka[k]>=1:
        print('Yes')
    else:
        print('No')

Submission status: Accepted

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

dic={}

for i in range(q):
    a=int(input())
    dic[a]=dic.get(a,0)+1

for i in range(1,n+1):
    win=dic.get(i,0)
    if k-(q-win)<=0:
        print("No")
    else:
        print("Yes")

Submission status: Accepted

Solution code:
N, K, Q = map(int, input().split())
A = [int(input()) for _ in range(Q)]

import collections
c = collections.Counter(A)
for n in range(1, N+1):
    if Q - c[n] >= K:
        print('No')
    else:
        print('Yes')

Submission status: Accepted

Solution code:
def main():
  import collections
  n, k, q, *a = map(int, open(0).read().split())
  point=[k-q]*n
  
  for person,getPoint in collections.Counter(a).items():
    point[person-1]+=getPoint
  
  for res in point:
    print("Yes" if res>0 else "No")
    
if __name__=="__main__":
  main()

Submission status: Accepted

Solution code:
def main():
  import sys
  import collections
  n,k,q=map(int,input().split())
  a=[int(e) for e in sys.stdin]
  point=[k-q]*n
  
  for person,getPoint in collections.Counter(a).items():
    point[person-1]+=getPoint
  
  for res in point:
    print("Yes" if res>0 else "No")
    
  
if __name__=="__main__":
  main()

Submission status: Accepted

Solution code:
x,y,z = map(int,input().split())
 
dp = [y-z for i in range(x)]
 
for j in range(z):
    k = int(input())
    dp[k-1] += 1
 
for l in dp:
    if l >= 1:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
import sys, re
from collections import deque, defaultdict, Counter
from math import ceil, sqrt, hypot, factorial, pi, sin, cos, radians
from itertools import accumulate, permutations, combinations, product
from operator import itemgetter, mul
from copy import deepcopy
from string import ascii_lowercase, ascii_uppercase, digits
from bisect import bisect, bisect_left
from fractions import gcd
from heapq import heappush, heappop
from functools import reduce

import numpy as np

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()))
sys.setrecursionlimit(10 ** 9)
INF = float('inf')
mod = 10 ** 9 + 7

N, K, Q = MAP()
A = np.array([INT() for _ in range(Q)])

point = [0]*N
for i in range(Q):
	point[A[i] - 1] += 1

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

Submission status: Accepted

Solution code:
x,y,z = map(int,input().split())

dp = [y-z for j in range(x)]

for i in range(z):
    a=int(input())
    dp[a-1] += 1

for i in dp:
    if 0 < i:
        print('Yes')
    else:
        print('No')

Submission status: Accepted

Solution code:
N,K,Q=map(int,input().split())
A=[0]*Q
for i in range(0,Q):
    A[i]=int(input())

B=[0]*(N+1)
for i in range(0,Q):
    B[A[i]-1]=B[A[i]-1]+1#各参加者の正解数

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

Submission status: Accepted

Solution code:
n,k,q = map(int,input().split())
kaitou = [0 for i in range(n)]
for i in range(q):
    a = int(input())
    kaitou[a-1] += 1
kaitou = [k-(q-i) for i in kaitou]
for i in kaitou:
    if i > 0:
        print('Yes')
    else:
        print('No')

Submission status: Accepted

Solution code:
N, K, Q = map(int, input().split())
correct_count = [0 for _ in range(N)]

for _ in range(Q):
    ai = int(input())
    correct_count[ai - 1] += 1

for c in correct_count:
    if K - Q + c < 1:
        print("No")
    else:
        print("Yes")

Submission status: Accepted

Solution code:
N, K, Q = map(int, input().split())
scores = [0] * N
for i in range(Q):
  x = int(input())
  scores[x-1] += 1
for i in range(N):
  if K + scores[i] - Q <=0:
    print("No")
  else:
    print("Yes")

Submission status: Accepted

Solution code:
N,K,Q=map(int,input().split())
points=[K-Q]*N
for i in range(Q):
   A_i=int(input())
   points[A_i-1]+=1

for j in range(N):
   if points[j]<=0:
      print("No")
   else:
      print("Yes")

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
points = [k-q]*n

for i in range(q):
    points[int(input())-1] += 1

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
from collections import Counter

N, K, Q = map(int ,input().split())
A = [int(input()) for _ in range(Q)]
c = Counter(A)

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n,k,q=map(int,input().split())
ans=[(k-q) for i in range(n)]

for i in range(q):
    a=int(input())
    ans[a-1]+=1

for an in ans:
    if an>=1:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
a = [int(input()) for _ in range(q)]
sc = {i : 0 for i in range(1, n+1)}
sc[0] = 0

for s in a:
  sc[s] += 1

del sc[0]
for s in sc.values():
  print("Yes" if (k-q+s)>0 else "No")

Submission status: Accepted

Solution code:
n,k,q = map(int,input().split())
a = [0 for  _ in range(q)]
point = [0 for _ in range(n)]

for i in range(q):
    a[i] = int(input())

for i in range(q):
    point[a[i]-1] += 1

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

Submission status: Accepted

Solution code:
import sys
N, K, Q = map(int, input().split())
A = (int(x) for x in sys.stdin.read().split())
score = [K - Q] * (N + 1)
for a in A:
  score[a] += 1
print("\n".join('Yes' if s > 0 else 'No 'for s in score[1:]))

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
n,k,q = map(int,input().split())
a = [int(input())-1 for i in range(q)]
cnt = [0]*n
for question in a:
    cnt[question] += 1
#print(cnt)#点数は k-q+cnt > 0
for man in range(n):
    if cnt[man] > q - k: print("Yes")
    else: print("No")

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split(' '))
answers = [int(input()) for _ in range(q)]

points = [0] * n
for a in answers:
  points[a-1] += 1
for p in points:
  if k - (q - p) > 0:
    print('Yes')
  else:
    print('No')

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
a_list = [int(input()) for i in range(q)]

point_dic = []
for i in range(n):
    point_dic.append(k-q)

for a in a_list:
    point_dic[a-1] = point_dic[a-1] + 1


for point in point_dic:
    if point > 0:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
n,k,q = map(int,input().split())
point = [0]*n
for i in range(q):
    a = int(input())-1
    point[a] += 1
for i in point:
    if q-i<k:
        print('Yes')
    else:
        print('No')

Submission status: Accepted

Solution code:
N,K,Q=map(int,input().split())
players=[K-Q]*N
for _ in range(Q):
    i=int(input())-1
    players[i]+=1
for num,p in enumerate(players):
    if p<=0:print('No')
    else: print('Yes')

Submission status: Accepted

Solution code:
n, k, q = list(map(int,input().split()))

point = [0]*n
seikai = [0]*n

for i in range(q):
    a = int(input())
    seikai[a-1] += 1
    
for i in range(n):
    point[i] = k - q + seikai[i] 
    if point[i] > 0:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
N, K, Q = map(int, raw_input().split())

P = [K-Q]*N
for i in range(Q):
  P[input()-1] += 1

for p in P:
  print "Yes" if p>0 else "No"

Submission status: Accepted

Solution code:
N, K, Q = map(int, input().split())
who_answered = [None]*Q
participants = [K-Q]*N

for i in range(Q):
    who_answered[i] = int(input()) - 1
    participants[who_answered[i]] += 1

for i in range(N):
    if participants[i] > 0:
        print('Yes')
    else:
        print('No')

Submission status: Accepted

Solution code:
n,k,q=map(int,input().split())
panel=[0]*n
for i in range(q):
  a=int(input())
  panel[a-1]+=1
  
for i in range(n):

  if panel[i]>q-k:
    print("Yes")
  else:
    print("No")

Submission status: Accepted

Solution code:
def main():
    n, k, q = [int(x) for x in input().split()]

    cleared = [0]*n
    for _ in range(q):
        cleared[int(input()) - 1] += 1

    sum_up = sum(cleared)
    point = [k]*n
    for i in range(n):
        print("Yes" if k + (cleared[i] - sum_up) > 0 else "No")


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
N,K,Q = map(int,input().split(" "))
score = [0]
for _ in range(N):
    score.append(K)

for _ in range(Q):
    ans = int(input())
    score[ans] +=1

for i in range(1,N+1):
    if score[i] > Q:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
a = []
for i in range(q):
  a.append(int(input()))
cnt = [0]*n
for i in range(q):
  cnt[a[i]-1] += 1
for i in range(n):
  point = k - (q - cnt[i])
  if point <= 0:
    print("No")
  else:
    print("Yes")

Submission status: Accepted

Solution code:
import numpy as np
N, K, Q = map(int, input().split())
first = K - Q
board = np.array([first] * N)
for _ in range(Q):
    A = int(input())
    board[A - 1] += 1
for player in board:
    if player > 0:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
import sys
N, K, Q = map(int, input().split())
A = (int(x) for x in sys.stdin.read().split())
score = [K - Q] * (N + 1)
for a in A:
  score[a] += 1
ans =  "\n".join('Yes' if s > 0 else 'No' for s in score[1:])
print(ans)

Submission status: Accepted

Solution code:
N, K, Q = map(int, input().split())
score = {str(i): 0 for i in range(1, N+1)}
for _ in range(Q):
  answerer = input()
  score[answerer] += 1

for k, v in sorted(score.items(), key=lambda x:int(x[0])):
  if K - (Q - v) > 0:
    print("Yes")
  else:
    print("No")

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
a = [int(input()) for _ in range(q)]
p = [k - q for _ in range(n)]

for i in a:
	p[i-1] += 1

for i  in p:
	if i >= 1:
		print("Yes")
	else:
		print("No")

Submission status: Accepted

Solution code:
import sys
N, K, Q = map(int, input().split())
A = (int(x) for x in sys.stdin.read().split())
score = [K - Q] * (N + 1)
for a in A:
  score[a] += 1
print("\n".join('Yes' if s > 0 else 'No' for s in score[1:]))

Submission status: Accepted

Solution code:
import sys
N, K, Q = map(int, input().split())
A = (int(x) for x in sys.stdin.read().split())
score = [K - Q] * N
for a in A:
  score[a - 1] += 1
for s in score:
  print('Yes' if s > 0 else 'No')

Submission status: Accepted

Solution code:
N, K, Q = map(int, input().split())
A = [int(input()) for _ in range(Q)]
ans = [K-Q]*N
for a in A:
    ans[a-1] += 1
for n in range(N):
    if ans[n] > 0:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
N,K,Q = [int(zz) for zz in input().split()]

li = [0]*N
for _ in range(Q):
    A = int(input())
    li[A-1] += 1

for i in range(N):
    if li[i]+K <= Q:
        print('No')
    else:
        print('Yes')

Submission status: Accepted

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

scores = {i: 0 for i in range(1, n+1)}
for _ in range(q):
    n = int(input())
    scores[n] += 1

for i, score in sorted(scores.items()):
    if k + score - q > 0:
        print('Yes')
    else:
        print('No')

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-

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


li = [0]*n
for i in range(q):
    a = int(input())
    li[a-1] += 1

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
# coding:UTF-8

N, life, Q = map(int, input().split())
points = [0 for i in range(0, N)]

for i in range(0, Q):
    points[int(input()) - 1] += 1
for n in points:
    if n > Q - life:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
N,K,Q=map(int,input().split())
A=list(int(input()) for i in range(Q))

kari = []
count = 0
for j in range(N):
    kari.append(K)

for k in range(Q):
    kari[A[k]-1]+=1
    count += 1
for i in range(N):
    kari[i]-=count
for m in range(N):
    if kari[m]>0:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
N, K ,Q = (int(nkq) for nkq in input().split())
A = []
score_list = [-1] + [K-Q for _ in range(N)]
for _ in range(Q):
    A.append(int(input()))

for a in A:
    score_list[a] += 1

for score in score_list[1:]:
    if score > 0:
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
n,k,q=list(map(int,input().split()))
s=[k]*n
for i in range(q):
  a=int(input())
  s[a-1]+=1
s=list(map(lambda x:x-q,s))
t=list(map(lambda x:print('Yes') if x>0 else print('No'),s))

Submission status: Accepted

Solution code:
n,k,q=map(int,input().split())
a=[]
while True:
  try:
    a.append(int(input()))
  except:
    break;
t=[0]*n
for i in a:
  t[i-1]+=1
for i in t:
  if i >= q - k + 1:
    print("Yes")
  else:
    print("No")

Submission status: Accepted

Solution code:
from itertools import groupby
N, K, Q = list(map(int, input().split()))
A = tuple(int(input()) for _ in range(Q))
d = {k:len(tuple(g)) for k, g in groupby(sorted(A))}
print("\n".join("Yes" if (d.get(i, 0) + K - Q) > 0 else "No" for i in range(1, N+1)))

Submission status: Accepted

Solution code:
N,K,Q = map(int, input().split())
li = [int(input()) for i in range(Q)]

t = [0] * N

for i in li:
  t[i-1] += 1

for i in t:
  if i >= Q - K + 1:
    print("Yes")
  else:
    print("No")

Submission status: Accepted

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

"""考え方
長さ=Nのリストに対して、数字を加算していく
最後に、要素の値がK未満の場合はYes、そうでないならNoと出力する
"""

ans = [0] * (N+1)

for q in range(0,Q):
  user = int(input())
  ans[user] += 1
  
limit = Q - K
for a in ans[1:]:
  if a > limit:
    print('Yes')
  else:
    print('No')

Submission status: Accepted

Solution code:
#!/usr/bin/env python3
import sys

YES = "Yes"  # type: str
NO = "No"  # type: str

def solve(N: int, K: int, Q: int, A: "List[int]"):

    a = [0] * N
    for i in range(len(A)):
       a[A[i]-1] += 1

    for i in range(len(a)):
        if K + a[i] > Q:
            print(YES)
        else:
            print(NO)
    return

def main():
    def iterate_tokens():
        for line in sys.stdin:
            for word in line.split():
                yield word
    tokens = iterate_tokens()
    N = int(next(tokens))  # type: int
    K = int(next(tokens))  # type: int
    Q = int(next(tokens))  # type: int
    A = [int(next(tokens)) for _ in range(Q)]  # type: "List[int]"
    solve(N, K, Q, A)

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
import sys
import math
import os
import itertools
import _collections
import string
from functools import lru_cache
import heapq

class cin():
    def int():
        return int(sys.stdin.readline().rstrip())
    def string():
        return sys.stdin.readline().rstrip()
    def mapInt():
        return [int(x) for x in cin.string().split()]
    def stringList(n):
        return [input() for i in range(n)]
    def intListList(n):
        return [cin.mapInt() for i in range(n)]
    def intColsList(n):
        return [int(input()) for i in range(n)]
        
class Math():
    def gcd(a,b):
        if b == 0:
            return a
        return Math.gcd(b,a % b)
    def lcm(a,b):
        return (a * b) // Math.gcd(a,b)
    def roundUp(a,b):
        return -(-a // b)
    def toUpperMultiple(a,x):
        return Math.roundUp(a,x) * x
    def toLowerMultiple(a,x):
        return (a // x) * x
    def nearPow2(n):
        if n <= 0:
            return 0
        if n & (n - 1) == 0:
            return n
        ret = 1
        while(n > 0):
            ret <<= 1
            n >>= 1
        return ret

MOD = int(1e09) + 7

def main():
    N,K,Q = cin.mapInt()
    A = [0] * N
    for i in range(Q):
        a = cin.int()
        A[a - 1] += 1
    for i in A:
        print("NYoe s"[K - (Q - i) > 0 ::2])
    return

if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
from sys import stdin
input = stdin.readline

n, k, q = map(int, input().split())
arr = list(int(input()) for _ in range(q))
cnt = [k] * n
for i in arr:
    cnt[i-1] += 1
print('\n'.join(['Yes' if cnt[i]-q>0 else 'No' for i in range(n)]))

Submission status: Accepted

Solution code:
import sys
N, K, Q = map(int, input().split())
A = (int(x) for x in sys.stdin.read().split())
score = [K - Q] * (N + 1)
for a in A:
  score[a] += 1
print("\n".join("No" if s <= 0 else "Yes" for s in score[1:]))

Submission status: Accepted

Solution code:
N, K, Q = map(int, input().split())
A = []
for i in range(Q):
  A.append(int(input()))
  
P = [K-Q for i in range(N)]

for i in A:
  P[i-1] += 1
  
for i in P:
  if i > 0:
    print("Yes")
  else:
    print("No")

Submission status: Accepted

Solution code:
n, k, q = map(int, input().split())
aq = [int(input()) for i in range(q)]
point = [k for i in range(n)]
correct_ans = [0 for i in range(n)]

for i in range(q):
    correct_ans[aq[i] - 1] += 1
    
point = ['Yes'  if p - (q - ca) > 0 else 'No' for (p, ca) in zip(point, correct_ans)]

for p in point:
    print(p)

Submission status: Accepted

Solution code:
from sys import stdin
input = stdin.readline

n, k, q = map(int, input().split())
arr = list(int(input()) for _ in range(q))
cnt = [k] * n
for i in arr:
    cnt[i-1] += 1
print('\n'.join(['Yes' if cnt[i]-q>0 else 'No' for i in range(n)]))

Submission status: Accepted

Solution code:
# -*- coding: utf-8 -*-
"""
Created on Fri Jan 24 14:57:54 2020

@author: manakamura
"""

tmp = input().split()
n,k,q = list(map(lambda a: int(a), tmp))

ppl=[]
for i in range(n):
    ppl.append(0)

for i in range(q):
    a=int(input())
#    print(a)
    ppl[a-1]+=1

#print(ppl)
#print("hofge")

for i in range(n):
    if(ppl[i]+k>q):
        print("Yes")
    else:
        print("No")

Submission status: Accepted

Solution code:
N, K, Q = map(int, input().split())
dic = {i: 0 for i in range(1, N+1)}
for i in range(Q):
  S = int(input())
  dic[S] += 1
for j in dic.keys():
  if K - Q + dic[j] > 0:
    print("Yes")
  else:
    print("No")

Submission status: Accepted

Solution code:
N,K,Q=map(int,input().split())
point=[K-Q]*N
result=[int(input())-1 for i in range(Q)]
for i in result:
    point[i]+=1

for r in point:
    if r > 0:
        print("Yes")
    else:
        print("No")