# | 제출 시각 | 아이디 | 문제 | 언어 | 결과 | 실행 시간 | 메모리 |
---|---|---|---|---|---|---|---|
161853 | boolodifjenula | Baza (COCI17_baza) | Cpython 3 | 625 ms | 36124 KiB |
이 제출은 이전 버전의 oj.uz에서 채점하였습니다. 현재는 제출 당시와는 다른 서버에서 채점을 하기 때문에, 다시 제출하면 결과가 달라질 수도 있습니다.
N,M=map(int,input().split())
L=[]
for i in range(N):
L+=[list(map(int,input().split()))]
Q=int(input())
R=Q*[0]
for x in range (Q):
Z=list(map(int,input().split()))
for y in range(N):
for z in range(M):
if Z[z]!=-1 and Z[z]!=L[y][z]:
break
if z==M-1:
R[x]+=1
for i in range(Q):
print(R[i])
# | Verdict | Execution time | Memory | Grader output |
---|---|---|---|---|
Fetching results... |