Problem:


Score : 200 points

Problem Statement

There are N pieces of source code. The characteristics of the i-th code is represented by M integers A_{i1}, A_{i2}, ..., A_{iM}.

Additionally, you are given integers B_1, B_2, ..., B_M and C.

The i-th code correctly solves this problem if and only if A_{i1} B_1 + A_{i2} B_2 + ... + A_{iM} B_M + C > 0.

Among the N codes, find the number of codes that correctly solve this problem.

Constraints

All values in input are integers.

1 \leq N, M \leq 20

-100 \leq A_{ij} \leq 100

-100 \leq B_i \leq 100

-100 \leq C \leq 100

Input

Input is given from Standard Input in the following format:

N M C
B_1 B_2 ... B_M
A_{11} A_{12} ... A_{1M}
A_{21} A_{22} ... A_{2M}
\vdots
A_{N1} A_{N2} ... A_{NM}

Output

Print the number of codes among the given N codes that correctly solve this problem.

Sample Input 1

2 3 -10
1 2 3
3 2 1
1 2 2

Sample Output 1

1

Only the second code correctly solves this problem, as follows:

Since 3 \times 1 + 2 \times 2 + 1 \times 3 + (-10) = 0 \leq 0, the first code does not solve this problem.

1 \times 1 + 2 \times 2 + 2 \times 3 + (-10) = 1 > 0, the second code solves this problem.

Sample Input 2

5 2 -4
-2 5
100 41
100 40
-3 0
-6 -2
18 -13

Sample Output 2

2

Sample Input 3

3 3 0
100 -100 0
0 100 100
100 100 100
-100 100 100

Sample Output 3

0

All of them are Wrong Answer. Except yours.



Sample input:
2 3 -10
1 2 3
3 2 1
1 2 2


Sample output:
1

Submission status: Accepted

Solution code:
import numpy as np
N,M,C = list(map(int,input().split(' ')))
B = np.array(list(map(int,input().split(' '))))
#print(B)
A = []
for i in range(N):
  A.append(list(map(int,input().split(' '))))
ans = 0
#print(A)

for i in range(N):
  A_ = np.array(A[i])
#  print((A_))
  test = (np.dot(B,A_))+ C
#  print('test',test)
  if (test) >0:
    ans+=1

print(ans)

Submission status: Accepted

Solution code:
import numpy as np

N, M, C = map(int, input().split())

ret = 0

B = np.array(list(map(int, input().split())))
for _ in range(N):
    A = np.array(list(map(int, input().split())))

    if np.dot(A, B) + C > 0:
        ret += 1

print(ret)

Submission status: Accepted

Solution code:
from operator import mul
n, m, c = map(int, input().split())
b = [int(i) for i in input().split()]
lst = []
for _ in range(n):
    lst.append(input().split())

sumlst = []

for i in lst:
    i = [ int(x) for x in i]
    res = [x * y for (x, y) in zip(i, b)]
    res = sum(res) + c
    if res > 0:
        sumlst.append(res)
    else:
        continue

print(len(sumlst))

Submission status: Accepted

Solution code:
n,m,c=map(int,input().split())
b=list(map(int,input().split()))
count = 0
for i in range(n):
    a=list(map(int,input().split()))
    dot = 0
    for al,bl in zip(a,b):
        dot += al*bl
    count += (dot+c)>0
print(count)

Submission status: Accepted

Solution code:
n,m,c=map(int,input().split())
b=list(map(int,input().split()))
ans=0
for i in range(n):
    a=list(map(int,input().split()))
    d=0
    for j in range(m):
       d+=a[j]*b[j]
    if(d+c>0):
        ans+=1
print(ans)

Submission status: Accepted

Solution code:
n,m,c=map(int,input().split())
b=list(map(int,input().split()))
ans=0
for i in range(n):
    a=list(map(int,input().split()))
    d=0
    for j in range(m):
       d+=a[j]*b[j]
    d+=c
    if(d<=0):
        continue
    else:
     ans+=1
print(ans)

Submission status: Accepted

Solution code:
n, m, c = map(int, input().split())
b = [int(num) for num in input().split()]
a = []
for i in range(n):
    a_r = [int(num) for num in input().split()]
    a.append(a_r)

count = 0
for an in a :
    sum = 0
    for j in range(m) :
        sum += an[j]*b[j]
    if (sum + c) > 0 :
        count += 1
print(count)

Submission status: Accepted

Solution code:
n1, n2, n3 = [int(i) for i in input().split()]

n4 = [int(j) for j in input().split()]

n5 = []  

for i1 in range(n1):
    n5.append([int(k) for k in input().split()])

r1 = 0
for i2 in range(n1):
    t1 = 0
    for i3 in range(n2):
        t1 += n4[i3] * n5[i2][i3]
    
    if (t1 + n3) > 0:
        r1 += 1

print(r1)

Submission status: Accepted

Solution code:
N,M,C = map(int,input().split())
B = list(map(int,input().split()))
ans = 0
A = []
for i in range(N):
    A.append(list(map(int,input().split())))
    S = C
    for j in range(M):
        S += A[i][j] * B[j]
    if S > 0:
        ans += 1
    else:
        ans += 0
print(ans)

Submission status: Accepted

Solution code:
n, m, c = map(int, input().split())
b = tuple(map(int, input().split()))
a = [tuple(map(int, input().split())) for i in range(n)]

ans = 0


for i in range(n):

    f = c

    for j in range(m):
        f += a[i][j] * b[j]


    if f > 0:
        ans += 1


print(ans)

Submission status: Accepted

Solution code:
n, m, c = map(int, input().split())
b = list(map(int, input().split()))

count = 0

for i in range(n):
  a = list(map(int, input().split()))
  sum = 0
  for j, xj in enumerate(a):
    sum += a[j] * b[j]
   
  if sum + c > 0:
    count += 1

print(count)

Submission status: Accepted

Solution code:
def abc():
    n, m, c = map(int, input().rstrip().split())
    bmap = list(map(int, input().rstrip().split()))
    cnt = 0
    for i in range(n):
        amap = list(map(int, input().rstrip().split()))
        if sum([a * b for a, b in zip(amap, bmap)]) + c > 0:
            cnt += 1
    print(cnt)


abc()

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))
A = [list(map(int, input().split())) for _ in range(N)]


# print(B)
# print(A)
# print(A[0][0])
ans = 0

for j in range(N):
    S = C
    for i in range(M):
        S += A[j][i] * B[i]
    if(S > 0):
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = [int(i) for i in input().split()]
A = [[int(i) for i in input().split()] for j in range(N)]
judge = 0
count = 0

for i in range(N):
    for j in range(M):
        judge += B[j] * A[i][j]
    if judge + C > 0:
        count += 1
    else:
        pass
    judge = 0

print(count)

Submission status: Accepted

Solution code:
import numpy as np
N,M,C = map(int,input().split())

B = np.array(input().split(), dtype=np.int32)
A = np.array([input().split() for _ in range(N)], dtype=np.int32)

answer = (((A*B).sum(axis = 1) + C) > 0).sum()
print(answer)

Submission status: Accepted

Solution code:
import numpy as np
n,m,c = list(map(int,input().split()))
b = np.array([list(map(int,input().split()))]).T
co_li = []
for x in range(n):
    co_li.append(list(map(int,input().split())))
a = np.array(co_li)
ans_li = np.dot(a,b) - (-1 * c)
print(np.count_nonzero(ans_li > 0))

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
n,m,c = map(int,input().split())
b = list(map(int,input().split()))
a = [input().split() for m in range(n)]
ans = 0
cnt = 0
for i in range(n):
    for j in range(m):
        cnt += int(a[i][j])*b[j]
    if cnt+c > 0:ans+=1
    cnt = 0
print(ans)

Submission status: Accepted

Solution code:
n,m,c = map(int,input().split())
B = list(map(int,input().split()))
A = []
for _ in range(n):
    d = list(map(int,input().split()))
    A.append(d)
ans = 0
sum = 0
for i in range(0,n):
    sum = c
    for j in range(0,m):
        sum += A[i][j]*B[j]
    if sum > 0:
        ans += 1
    else:
        ans += 0

print(ans)

Submission status: Accepted

Solution code:
N,M,C=map(int,input().split())
Bs=[int(b) for b in input().split()]

c=0
for n in range(N):
    As=[int(a) for a in input().split()]
    r = sum([a*b for a,b in zip(As,Bs)]) + C
    if r>0:
        c+=1
    #print(r)
print(c)

Submission status: Accepted

Solution code:
N,M,C = map(int,input().split())
B = list(map(int,input().split()))
count = 0
for i in range(N):
    A = list(map(int,input().split()))
    total = C
    for j in range(M):
        total += A[j]*B[j]
    if total > 0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
n, m , c = map(int, input().split())
b_li = list(map(int, input().split()))
ans = 0
for i in range(n):
    a_li = list(map(int, input().split()))
    if sum(a * b for a, b in zip(a_li, b_li)) + c > 0:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
n, m, c = map(int, input().split())
b = list(map(int, input().split()))
k = 0
a = []
for i in range(n):
  a.append(list(map(int, input().split())))
for i in range(n):
  s = 0
  for j in range(m):
    s += a[i][j]*b[j]
  if s + c > 0:
    k += 1
  
print(k)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))
ans = 0
for _ in range(N):
    A = map(int, input().split())
    ans += sum(a * b for a, b in zip(A,B)) + C > 0
print(ans)

Submission status: Accepted

Solution code:
import numpy as np

N,M,C=map(int,input().split())
B=list(map(int,input().split()))
A=[list(map(int,input().split())) for _ in range(N)]

ans=0
for i in range(N):
    if np.dot(A[i],B)+C>0:ans+=1
print(ans)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))
A = [list(map(int, input().split())) for _ in range(N)]
X = 0
for i in range(N):
  Y = C
  for j in range(M):
    Y += A[i][j]*B[j]
  if Y > 0:
    X += 1
print(X)

Submission status: Accepted

Solution code:
n,m,c = map(int,input().split())
li = []
for i in range(n+1):
	li.append(list(map(int,input().split())))

cnt = 0
for i in range(1,n+1):
  tmp = 0
  for j in range(m):
    tmp += li[i][j] * li[0][j]
  tmp += c
  if tmp > 0:
    cnt += 1
    
print(cnt)

Submission status: Accepted

Solution code:
N,M,C = map(int,input().split())
B = list(map(int,input().split()))
A = [list(map(int,input().split())) for _ in range(N)]

ans = 0
for a in A:
    tmp_sum = 0
    for j in range(M):
        tmp_sum += a[j]*B[j]
    if tmp_sum+C > 0:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
import numpy as np

n,m,c=map(int,input().split())
b=np.array(list(map(int,input().split())))
ans=0
for i in range(n):
    a=np.array(list(map(int,input().split())))
    if np.dot(a,b)+c>0:
        ans+=1
    
print(ans)

Submission status: Accepted

Solution code:
import numpy as np
ans = 0
n,m,c = map(int, input().split())
b = list(map(int, input().split()))
for i in range(n):
    a = list(map(int, input().split()))
    arrayA = np.array(a)
    arrayB = np.array(b)
    array = arrayA * arrayB
    if array.sum() + c > 0:
        ans += 1
    
print(ans)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
bl = list(map(int, input().split()))
ans = 0
for i in range(N):
  l = list(map(int, input().split()))
  tmp = 0
  for j in range(M):
    tmp += bl[j] * l[j]
  if tmp + C > 0:
    ans += 1
print(ans)

Submission status: Accepted

Solution code:
n,m,c=map(int,input().split())
b=list(map(int,input().split()))
a=[]
for _ in range(n):
  d=list(map(int,input().split()))
  a.append(d)
x=0
for i in range(n):
  s=c
  for j in range(m):
    s=s+a[i][j]*b[j]
  if s>0:
    x+=1
print(x)

Submission status: Accepted

Solution code:
N,M,C = list(map(int,input().split(" ")))
B = list(map(int,input().split(" ")))
A = [list(map(int,input().split(" "))) for i in range(N)]
ans = []
for i in range(len(A)):
    total=0
    for j in range(len(A[0])):
        #print(A[i][j]*B[j])
        total+=A[i][j]*B[j]
    total+=C
    if total>0:
        ans.append(total)

print(len(ans))

Submission status: Accepted

Solution code:
n,m,c=map(int,input().split())
b=list(map(int,input().split()))
d=0
ans=0
for _ in range(n):
    a=list(map(int,input().split()))
    for j in range(m):
        d+=a[j]*b[j]
    if d+c >0:
        ans+=1
        d=0
    else:
        d=0
print(ans)

Submission status: Accepted

Solution code:
n,m,c=map(int,input().split())
a=[list(map(int,input().split())) for i in range(n+1)]
count=0
for i in range(n):
  sum=c
  for j in range(m):
    sum+=a[i+1][j]*a[0][j]
  if sum>0:
    count+=1
print(count)

Submission status: Accepted

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

ans = 0
cnt = 0
for j in range(n):
    for i in range(m):
        ans += a[j][i] * b[i]
    if (ans + c) > 0:
        cnt += 1
    ans = 0

print(cnt)

Submission status: Accepted

Solution code:
N,M,C=map(int,input().split())
B=list(map(int,input().split()))
ans=0

for _ in range(N):
    A=list(map(int,input().split()))
    correctness=C
    for i in range(M):
        correctness+=A[i]*B[i]
    if correctness>0:
        ans+=1
    
print(ans)

Submission status: Accepted

Solution code:
'''
allinputs = iter(input().splitlines())
input = lambda : next(allinputs)
#'''

N, M, C = map(int, input().split())
B = list(map(int, input().split()))
A = [list(map(int, input().split())) for _ in range(N)]

count = 0

for i in range(N):
	tmp = 0
	for j in range(M):
		tmp += A[i][j] * B[j]
		
	if tmp + C > 0:
		count += 1

print(count)

Submission status: Accepted

Solution code:
N, _, c = map(int, input().split())
b = [int(x) for x in input().split()]

ans = 0

for _ in range(N):
    a = [int(x) for x in input().split()]
    sm = 0
    for ai, bi in zip(a, b):
        sm += ai*bi
    if sm + c > 0:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
n,m,c = map(int,input().split())
b = list(map(int,input().split()))
count = 0
for i in range(n):
    a = list(map(int,input().split()))
    p = c
    for j in range(m):
        p += a[j]*b[j]
    if p > 0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
N, M, C = list(map(int, input().split()))
B = list(map(int, input().split()))
A = [list(map(int, input().split())) for i in range(N)]

ans = 0
for i in range(N):
    code = 0
    for j in range(M):
        code += B[j] * A[i][j]
    if code + C > 0:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
def resolve():
	N,M,C=map(int,input().split())
	B=list(map(int,input().split()))
	ans=0
	for i in range(N):
		A=list(map(int,input().split()))
		chk=0
		for j in range(M):
			chk+=A[j]*B[j]
		if chk+C>0:
			ans+=1
	print(ans)
resolve()

Submission status: Accepted

Solution code:
num = [int(i) for i in input().split()]
coefficient = [int(i) for i in input().split()]
source_code_set = [[int(i) for i in input().split()]for j in range(num[0])]
sum = 0
count = 0

for i in range(num[0]):
    for j in range(num[1]):
        sum += source_code_set[i][j] * coefficient[j]
    if sum + num[2] > 0:
        count += 1
    sum = 0

print(count)

Submission status: Accepted

Solution code:
n,m,c=map(int,input().split())
b=list(map(int,input().split()))
ans=0
for i in range(n):
  a=list(map(int,input().split()))
  check=0
  for j in range(m):
    check+=a[j]*b[j]
  if check>-c:
    ans+=1
print(ans)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = [int(i) for i in input().split()]
A = [[int(i) for i in input().split()] for j in range(N)]
c = 0
for i in range(N):
    if sum([A[i][j] * B[j] for j in range(len(B))]) + C > 0:
        c += 1
print(c)

Submission status: Accepted

Solution code:
nmc = input().split()
lstb = input().split()
a = []
for n in range(int(nmc[0])):
    a.append(input().split())
total = 0
count = 0
for n in range(int(nmc[0])):
    for m in range(int(nmc[1])):
        total += (int(lstb[m]) * int(a[n][m]))
    if total + int(nmc[2]) > 0:
        count += 1
    total = 0
print(count)

Submission status: Accepted

Solution code:
n, m, c = (int(i) for i in input().split())
B = [int(i) for i in input().split()]
A = [input() for j in range(n)]

import numpy as np

b = np.array(B)

num = 0
for i in range(n):
    aa = np.array([int(j) for j in A[i].split()])
    if np.sum(aa.dot(b)) + c > 0:
         num += 1
print(num)

Submission status: Accepted

Solution code:
n,m,c=map(int,input().split())
b=[int(i) for i in input().split()]
ans=0
for i in range(n):
    a=[int(i) for i in input().split()]
    if sum(a[j]*b[j] for j in range(m))+c>0:
        ans+=1
print(ans)

Submission status: Accepted

Solution code:
 # -*- coding: utf-8 -*-
import numpy as np
     
[N, M, C] = [int(i) for i in input().split()]
B = np.array([int(i) for i in input().split()])
A_N = []
for n in range(N):
    A = np.array([int(i) for i in input().split()])
    A_N.append(A)

count = 0
for n in range(N):
    dot = np.dot(B, A_N[n])
    if dot + C > 0:
        count += 1

print(count)

Submission status: Accepted

Solution code:
N,M,C = (int(i) for i in input().split())

B = list(int(i) for i in input().split())
A = []
for i in range(N):
  A.append(list(int(i) for i in input().split()))

ans = 0
for i in range(N):
  check = 0
  for j in range(M):
    check += A[i][j]*B[j]
  if check + C >0:
    ans +=1

print(ans)

Submission status: Accepted

Solution code:
import numpy as np

N , M , C = map(int,input().split())
B = np.array(list(map(int,input().split())))
A = [0] * N

for i in range(N) :
    A[i] = list(map(int,input().split()))

A = np.array(A)
AB = A.dot(B)

ans = 0

for i in range(N) :
    if AB[i] + C > 0 :
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
n, m, c = [int(i) for i in input().split()]
b_list = [int(i) for i in input().split()]

answer = 0
for j in range(n):
  a_list = [int(i) for i in input().split()]
  sum_of_feature = c
  for (b, a) in zip(b_list, a_list):
    sum_of_feature += b * a
  if sum_of_feature > 0:
    answer += 1

print(answer)

Submission status: Accepted

Solution code:
N,M,C = map(int,input().split())
B = list(map(int,input().split()))

ans = 0

for i in range(N):
    temp_score = C
    A = list(map(int,input().split()))
    for j in range(M):
        temp_score += A[j] * B[j]

    if(temp_score > 0):
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
N,M,C = map(int,input().split())
B = list(map(int,input().split()))
A = [list(map(int,input().split())) for i in range(N)]
result = 0

for i in range(N):
    sum = 0
    for (a,b) in zip(B,A[i]):
        sum += a*b
    if sum + C > 0:
        result += 1
print(result)

Submission status: Accepted

Solution code:
n,m,c = map(int, input().split())
bdata = [int(iz) for iz in input().split()]
adata = [list(map(int, input().split())) for _ in range(n)]

c_max = 0

for i in range(n):
    ans = 0
    for j in range(m):
        ans = ans  +  int(adata[i][j]) * bdata[j]
    if ans + c > 0:
        c_max += 1

print(c_max)

Submission status: Accepted

Solution code:
n, m, c = map(int, input().split())
b = [int(i) for i in input().split()]
a = [input() for j in range(n)]
import numpy as np
b = np.array(b)
num = 0
for i in range(n):
    aa = np.array([int(j) for j in a[i].split()])
    if np.sum(aa.dot(b)) + c > 0:
        num += 1
print(num)

Submission status: Accepted

Solution code:
import numpy as np

N, M, C = map(int, input().split())
B = list(map(int, input().split())) 
A = np.zeros((N,M))



for i,_ in enumerate(A):
    A[i:] = list(map(int, input().split())) 

cnt = 0
z = 0
for A_line in A:
    for i,a in enumerate(A_line):
        z = z + a*B[i]
    if z+C >0:
        cnt += 1
    z = 0

print(cnt)

Submission status: Accepted

Solution code:
n, m, c = map(int, input().split())
b = list(map(int, input().split()))  
a = [[int(i) for i in input().split()] for i in range(n)]
cnt = 0
list1 = []
list2 = []
for j in range(n):
    for k in range(m):
        integer = a[j][k] * b[k]
        list1.append(integer)
    list2.insert(0, list1)
    list1 = []
for l in range(n):
    if sum(list2[l]) + c > 0:
        cnt += 1 
print(cnt)

Submission status: Accepted

Solution code:
n,m,c = map(int, input().split())
b = list(map(int, input().split()))
a = []
for i in range(n):
  a.append(list(map(int, input().split())))
count = 0

for i in range(n):
  s = c
  for j in range(m):
    s += a[i][j]*b[j]
  if s > 0:
    count += 1

print(count)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))

count = 0

for i in range(N):
  A = list(map(int, input().split()))
  
  if sum([a * b for a, b in zip(A, B)]) + C > 0:
    count += 1
    
print(count)

Submission status: Accepted

Solution code:
import numpy as np

n, m, c = map(int, input().split())
b = np.array(list(map(int, input().split()))).reshape(-1, 1)

a = np.array(list(map(int, input().split()))).reshape(1,-1)
for i in range(n-1):
    a = np.vstack([a, np.array(list(map(int, input().split()))).reshape(1, -1)])

res = np.dot(a, b).reshape(-1) + c
print(np.sum(res > 0))

Submission status: Accepted

Solution code:
n,m,c=map(int,input().split())
b=[int(i) for i in input().split()]
a=[[int(i) for i in input().split()] for j in range(n)]
x=0
for i in range(n):
    y=0
    for j in range(m):
        y+=a[i][j]*b[j]
    if y+c>0:
        x+=1
print(x)

Submission status: Accepted

Solution code:
N,M,C = map(int, input().split())
B = list(map(int, input().split()))

ans = 0

for _ in range(N):

    sum = 0
    A = list(map(int, input().split()))

    for i in range(M):
        sum += A[i]*B[i]
        
    if sum + C > 0:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
N,M,C=map(int,input().split())
B=list(map(int,input().split()))
n=0
for i in range(N):
  A=list(map(int,input().split()))
  s=0+C
  for a,b in zip(A,B):
    c=a*b
    s=s+c
  if s >0:
    n=n+1
print(n)

Submission status: Accepted

Solution code:
from functools import reduce


def add(x, y):
    return x + y


n, m, c = list(map(int, input().split()))
a, *b = [list(map(int, input().split())) for i in range(n + 1)]
success = 0

for i in range(n):
    if reduce(add, list(x * y for (x, y) in zip(a, b[i]))) + c > 0:
        success += 1

print(success)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))
ans = 0

for i in range(N):
	A = list(map(int, input().split()))
	feature = C

	for j in range(M):
		feature += B[j] * A[j]

	if feature > 0:
		ans += 1

print(ans)

Submission status: Accepted

Solution code:
#https://atcoder.jp/contests/abc121/tasks/abc121_b

import numpy as np

n,m,c=map(int,input().split())
blist=np.array(list(map(int,input().split())))
alist=np.array([list(map(int,input().split())) for i in range(n)])

count=0

for i in range(n):
	if np.sum(alist[i]*blist)+c > 0:
		count += 1

print(count)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
blst = [i for i in map(int, input().split())]
alst = []
for i in range(N):
    alst.append([j for j in map(int, input().split())])

ans = 0
for i in range(N):
    score = C
    for j in range(M):
        score += alst[i][j] * blst[j] 
    if score > 0:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
N, M, C = [int(x) for x in input().split()]
B = [int(x) for x in input().split()]

count = 0
for _ in range(N):
    A = [int(x) for x in input().split()]

    if sum(a * b for a, b in zip(A, B)) + C > 0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
N,M,C = map(int,input().split())

B = list(map(int,input().split()))

cnt = 0
for i in range(N):
    A = list(map(int,input().split()))
    dic = 0
    for j in range(M):
        dic += A[j]*B[j]
    dic += C
    if dic > 0:
        cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
n, m, c = [ int(v) for v in input().split() ]
b_list =  [ int(v) for v in input().split() ]

ans = 0
for i in range(n):
  a_list =  [ int(v) for v in input().split() ]
  if sum([ (a_list[i] * b_list[i]) for i in range(m) ]) + c > 0:
    ans += 1

print(ans)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))
A = [[] for i in range(N)]
for i in range(N):
    A[i] = list(map(int, input().split()))
count = 0
for i in range(len(A)):
    _sum = 0
    for j in range(len(B)):
        for k in range(len(A[i])):
            if j == k:
                _sum += B[j] * A[i][k]
    if _sum + C > 0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))
A = [[] for i in range(N)]
count = 0
for i in range(N):
    A[i] = list(map(int, input().split()))
for i in range(N):
    y = 0
    for j in range(M):
        y += B[j]*A[i][j] 
    if y+C > 0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
N,M,C=map(int, input().split())
B=list(map(int, input().split()))
A=[]
ans=0
a=0
for i in range(N):
    A.append([int(j) for j in input().split()])
for i in range(N):
    for j in range(M):
         a+=A[i][j]*B[j]
    if a+C>0:
        ans+=1
        a=0
    else:
        a=0
print(ans)

Submission status: Accepted

Solution code:
n, m, c= list(map(int, input().split()))
b = list(map(int, input().split()))
a = [list(map(int, input().split())) for i in range(n)]
count = 0
for i in range(n):
    ans = 0
    for j in range(m):
        ans += b[j]*a[i][j]
    ans += c
    if ans>0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
import numpy as np

N, M, C = [int(x) for x in input().split()]
B = np.array([int(x) for x in input().split()])
A = np.empty((N,M))

count = 0
for n in range(N):
    A[n] = [int(m) for m in input().split()]
    count += (sum(A[n] * B)+C > 0)
print(count)

Submission status: Accepted

Solution code:
import numpy as np

N, M, C = [int(x) for x in input().split()]
B = np.array([int(x) for x in input().split()])
A = np.empty((N,M))

count = 0
for n in range(N):
    A[n] = [int(m) for m in input().split()]
    #count = count + 1 if sum(A[n] * B)+C > 0 else count 
    count += (sum(A[n] * B)+C > 0)
print(count)

Submission status: Accepted

Solution code:
import numpy as np

N, M, C = [int(x) for x in input().split()]
B = np.array([int(x) for x in input().split()])
A = np.empty((N,M))

count = 0
for n in range(N):
    A[n] = [int(m) for m in input().split()]
    count = count + 1 if sum(A[n] * B)+C > 0 else count 
print(count)

Submission status: Accepted

Solution code:
import numpy as np
from operator import mul
from functools import reduce

N, M, C = [int(x) for x in input().split()]
B = np.array([int(x) for x in input().split()])
#A = np.array([[0]*M,N])
A = np.empty((N,M))

result = np.array([])
count = 0

for n in range(N):
    A[n] = [int(m) for m in input().split()]
    #result = A[n] * B
    if sum(A[n] * B)+C > 0:
        count +=1
print(count)

Submission status: Accepted

Solution code:
import numpy as np
from operator import mul
from functools import reduce

N, M, C = [int(x) for x in input().split()]
B = np.array([int(x) for x in input().split()])
#A = np.array([[0]*M,N])
A = np.empty((N,M))

result = np.array([])
count = 0

for n in range(N):
    A[n] = [int(m) for m in input().split()]
    result = A[n] * B
    #print(result)
    if sum(result)+C > 0:
        count +=1
print(count)

Submission status: Accepted

Solution code:
data = list(map(int,input().split()))
n = data[0]
m = data[1]
c = data[2]
b = list(map(int,input().split()))
a = []
for i in range(n):
        a.append(list(map(int,input().split())))
result = 0
for i in range(n):
        sum_ = c
        for j in range(m):
                sum_ += a[i][j]*b[j]
        if sum_ > 0:
                result += 1
print(result)

Submission status: Accepted

Solution code:
N , M , C = map(int,input().split())
B = list(input().split())

count = 0

for i in range(N):
    multipl = 0
    A = list(input().split())
    for i in range(M):
        multipl = float(A[i]) * float(B[i]) + multipl
    if (multipl + C) > 0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))
A = [0 for i in range(N)]
for i in range(N):
    A[i] = list(map(int,input().split()))

counter = 0
for i in range(N):
    sum = 0
    for j in range(M):
        sum += A[i][j]*B[j]
    sum += C
    if sum > 0:
        counter += 1

print(counter)

Submission status: Accepted

Solution code:
# -- coding:utf-8 --
n,m,c=map(int,input().split())
B = list(map(int,input().split()))
A = [list(map(int,input().split())) for _ in range(n)]

count = 0

for ii in range(n):
    temp = [0] * m
    for jj in range(m):
        temp[jj] = A[ii][jj]*B[jj]
    if sum(temp) + c > 0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split(" "))
B_list = [int(i) for i in input().split(" ")]
ans = 0
for i in range(N):
    y = 0
    A_list = [int(k) for k in input().split(" ")]
    for j in range(M):
        y += A_list[j] * B_list[j]
    if y + C > 0:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
import numpy as np
n, m, c = map(int, input().split())
b = []
a = list(map(int, input().split()))
for _ in range(n):
    tmp = list(map(int, input().split()))
    b.append(tmp)

ary_a = np.array(a)
ary_b = np.array(b)

ans = np.dot(ary_b, ary_a)
cnt = 0
for i in range(len(ans)):
    if ans[i] + c > 0:
        cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
#Coding:Utf-8

N, M, C= map(int, input().split())
B=list(map(int, input().split()))
count=0
for i in range(N):
    A=[]
    total=0
    A=list(map(int, input().split()))
    for j in range(M):
        total=total+(A[j]*B[j])
    else:
        if total+C>0:
            count+=1

print(count)

Submission status: Accepted

Solution code:
n,m,c = map(int,input().split())
b = list(map(int,input().split()))
count = 0
for i in range(n):
  s = 0
  a = list(map(int,input().split()))
  for k in range(m):
    s += a[k]*b[k]
  s += c
  if s > 0:
    count += 1
print(count)

Submission status: Accepted

Solution code:
import numpy as np

n,m,c = map(int,input().split())
b = np.array(list(map(int,input().split())))
f=0
for i in range(n):
    a = np.array(list(map(int,input().split())))
    f += (np.dot(a,b)+c>0)
print(f)

Submission status: Accepted

Solution code:
from collections import defaultdict, Counter
from itertools import product, groupby, count, permutations, combinations
from math import pi, sqrt
from collections import deque
from bisect import bisect, bisect_left, bisect_right
from string import ascii_lowercase
from functools import lru_cache
import sys
sys.setrecursionlimit(10000)
INF = float("inf")
YES, Yes, yes, NO, No, no = "YES", "Yes", "yes", "NO", "No", "no"
dy4, dx4 = [0, 1, 0, -1], [1, 0, -1, 0]
dy8, dx8 = [0, -1, 0, 1, 1, -1, -1, 1], [1, 0, -1, 0, 1, 1, -1, -1]


def inside(y, x, H, W):
    return 0 <= y < H and 0 <= x < W


def ceil(a, b):
    return (a + b - 1) // b


# aとbの最大公約数
def gcd(a, b):
    if b == 0:
        return a
    return gcd(b, a % b)

# aとbの最小公倍数
def lcm(a, b):
    g = gcd(a, b)
    return a / g * b


def main():
    N, M, C = map(int, input().split())

    B = list(map(int, input().split()))

    ans = 0
    for _ in range(N):
        A = list(map(int, input().split()))

        total = C
        for i in range(M):
            total += A[i] * B[i]

        ans += total > 0

    print(ans)


if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))
cnt = 0

for i in range(N):
  A = list(map(int, input().split()))
  sum = C
  for j, k in zip(A, B):
    sum += j*k
  if sum > 0:
    cnt += 1

print(cnt)

Submission status: Accepted

Solution code:
N, M, C = list(map(int, input().split()))
b = list(map(int, input().split()))
sum = 0
cnt = 0
for i in range(N):
    a = list(map(int, input().split()))
    for j in range(M):
        sum += a[j]*b[j]
    if sum + C > 0 :
        cnt += 1
    sum = 0
print(cnt)