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:
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):
    sum = 0

    for j in range(m):
        sum = sum + A[i][j] * B[j]

    sum = sum + c

    if sum > 0:
        ans = ans + 1

print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import io

nim, mike, kite = map(int, input().split(' '))
tim = list(map(int, input().split(' ')))
data = 0
for _ in range(nim):
    a = list(map(int, input().split(' ')))
    if sum([x * y for x, y in zip(a, tim)]) + kite > 0:
        data += 1
print(data)

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)]
cnt = 0

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

Submission status: Accepted

Solution code:
import sys
input = sys.stdin.readline
import numpy as np


def read():
    N, M, C = map(int, input().strip().split())
    B = np.empty(M, dtype=np.int)
    A = np.empty((N, M), dtype=np.int)
    B[:] = input().strip().split()
    for i in range(N):
        A[i] = input().strip().split()
    return N, M, C, B, A

def solve(N, M, C, B, A):
    return np.count_nonzero(np.sum(A*B, axis=1) + C > 0)

if __name__ == '__main__':
    inputs = read()
    print(solve(*inputs))

Submission status: Accepted

Solution code:
import math

n, m, c = map(int, input().split())
b_list = list(map(int, input().split()))

passed = 0
for i in range(n):
    a_list = list(map(int, input().split()))
    total = 0
    for j in range(len(a_list)):
        total += a_list[j] * b_list[j]
    if (total + c > 0):
        passed += 1

print(passed)

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 = c
    for k in range(m):
        d+=a[k]*b[k]
    if d>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 = c
    for k in range(m):
        d+=a[k]*b[k]
    if d>0:
        ans+=1
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys,os
from collections import defaultdict, deque
from math import ceil, floor
if sys.version_info[1] >= 5:
    from math import gcd
else:
    from fractions import gcd
sys.setrecursionlimit(10**6)
write = sys.stdout.write
dbg = (lambda *something: print(*something)) if 'TERM_PROGRAM' in os.environ else lambda *x: 0
def main(given=sys.stdin.readline):
    input = lambda: given().rstrip()
    LMIIS = lambda: list(map(int,input().split()))
    II = lambda: int(input())
    MOD = 10**9+7
    #あいうえお
    N,M,C = LMIIS()
    B = LMIIS()
    A = [LMIIS() for _ in range(N)]

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

    

if __name__ == '__main__':
    main()

Submission status: Accepted

Solution code:
#coding:utf-8
import sys,os
from collections import defaultdict, deque
from math import ceil, floor
if sys.version_info[1] >= 5:
    from math import gcd
else:
    from fractions import gcd
sys.setrecursionlimit(10**6)
write = sys.stdout.write
dbg = (lambda *something: print(*something)) if 'TERM_PROGRAM' in os.environ else lambda *x: 0
def main(given=sys.stdin.readline):
    input = lambda: given().rstrip()
    LMIIS = lambda: list(map(int,input().split()))
    II = lambda: int(input())
    MOD = 10**9+7
    
    N,M,C = LMIIS()
    B = LMIIS()
    A = [LMIIS() for _ in range(N)]

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

    

if __name__ == '__main__':
    main()

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()))
    total = 0
    for a, b in zip(A, B):
        total += a*b
    total += C
    if total > 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)]
cnt=0
judge=0
for i in range(N):
    for j in range(M):
        judge+=a[i][j]*b[j]
    if judge+C>0:
        cnt+=1
    judge=0
print(cnt)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import bisect
import copy
import heapq
import sys
import itertools
import queue
input = sys.stdin.readline
sys.setrecursionlimit(1000000)
mod = 10 ** 9 + 7

def read_values(): return map(int, input().split())
def read_index(): return map(lambda x: int(x) - 1, input().split())
def read_list(): return list(read_values())
def read_lists(N): return [read_list() for n in range(N)]


class V:
    def __init__(self, f, v=None):
        self.f = f
        self.v = v
 
    def __str__(self):
        return str(self.v)
 
    def ud(self, n):
        if n is None:
            return

        if self.v is None:
            self.v = n
            return
        self.v = self.f(self.v, n) 


def main():
    N, M, C = read_values()
    B = read_list()

    res = 0
    for _ in range(N):
        A = read_list()
        if sum(a * b for a, b in zip(A, B)) + C > 0:
            res += 1

    print(res)


if __name__ == "__main__":
    main()

Submission status: Accepted

Solution code:
n , m , c = map(int,input().split())
b = list(map(int,input().split()))
a = []
count = 0
x = 0

for i in range(n):
    a.append(list(map(int,input().split())))
#print(a)


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

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = [int(x) for x in input().split()]
ans = 0
for i in range(N):
    A = [int(y) for y in input().split()]
    S = 0
    for j in range(M):
        S += A[j] * B[j]
    if S + 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 = []
while True:
  try:
    tmp = list(map(int,input().split()))
    A.append(tmp)
  except:
    break
correct = 0
for i in range(n):
  eq = 0
  for j in range(len(B)):
    eq += A[i][j]*B[j]
  if eq>-c:
    correct +=1
print(correct)

Submission status: Accepted

Solution code:
if __name__ == "__main__":
    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):
        tmp = c
        for j in range(m):
            tmp += a[i][j] * b[j]
        if tmp > 0:
            ans += 1

    print(ans)

Submission status: Accepted

Solution code:
import numpy as np
N,M,C=[int(i)for i in input().split()]
B=np.array([int(b)for b in input().split()])
A=np.array([[int(a)for a in input().split()]for _ in range(N)])
#print([c>0 for c in A*B])
#print([c>0 for c in np.dot(A,B)])
ans=sum([c+C>0 for c in np.dot(A,B)])
#print(B)
#print()
#print(A)
print(ans)

Submission status: Accepted

Solution code:
#B - Can you solve this?
N,M,C= 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):
    ans = 0
    for j in range(M):
        ans += A[i][j]*B[j]
    ans += C
    if ans > 0 :
        Ans += 1
    else:
        pass
if Ans >= 0:
    print(Ans)
else:
    print(0)

Submission status: Accepted

Solution code:
N,M,C=map(int,input().split())
B=[int(i) for i in input().split()]
ans=0
for t in range(N):
    A=[int(i) for i in input().split()]
    ANS=0
    for s in range(M):
        ANS+=A[s]*B[s]
    if ANS+C>0:
        ans+=1
print(ans)

Submission status: Accepted

Solution code:
N, M, C = map(int,input().split())
B = list(map(int,input().split()))
cnt = 0
for _ in range(N):
    ans = 0
    A = list(map(int,input().split()))
    for i in range(M):
        ans += A[i] * B[i]
    ans += C
    if ans > 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 i in range(N):
    temp = C
    for j in range(M):
        temp += A[i][j]*B[j]
    if temp > 0:
        ans += 1
print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
import sys
readline = sys.stdin.buffer.readline
readlines = sys.stdin.buffer.readlines
read = sys.stdin.buffer.read
sys.setrecursionlimit(10 ** 7)

N, M, C = map(int, readline().split())
B = list(map(int, readline().split()))

ans = 0
for _ in range(N):
    A = map(int, readline().split())
    code_sum = C
    for a, b in zip(A, B):
        code_sum += a*b
    if code_sum > 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):
    kar = 0
    a = list(map(int,input().split()))
    for j in range(m):
        kar += a[j]*b[j]
    if kar + c > 0:
        ans += 1
print(ans)

Submission status: Accepted

Solution code:
#5
n,m,c = map(int,input().split())

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


cnt = 0

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

Submission status: Accepted

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

Submission status: Accepted

Solution code:
N,M,C=map(int,input().split())
B=list(map(int,input().split()))
A=[]
ans=0
AB=[]
for i in range(N):
    a=list(map(int,input().split()))
    ab=[0]*M
    for i in range(M):
        ab[i]=a[i]*B[i]
    AB.append(ab)
for i in range(N):
    if sum(AB[i])>(-1)*C:
        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):
    ai=list(map(int,input().split()))
    a.append(ai)
ans = 0
for i in range(n):
    t=c
    for j in range(m):
        t+=a[i][j]*b[j]
    ans += 1 if t > 0 else 0
print(ans)

Submission status: Accepted

Solution code:
# Python3 (3.4.3)
import sys
input = sys.stdin.readline

# -------------------------------------------------------------
# function
# -------------------------------------------------------------


# -------------------------------------------------------------
# main
# -------------------------------------------------------------
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):
    x = C
    for j in range(M):
        x += A[i][j]*B[j]
    if x > 0:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
import numpy as np
n,m,c = map(int,input().split())
b = list(map(int,input().split()))
b = np.array(b)
count = 0
for i in range(n):
  a = list(map(int,input().split()))
  a = np.array(a)
  if np.sum(np.multiply(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()))
A = [list(map(int, input().split())) for _ in range(N)]

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

    if sm > 0:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
from operator import mul
def p(): return map(int, input().split())
n, _, c = p()
b = list(p())
u = 0
for _ in range(n):
    v = sum(map(mul, b, list(p()))) + c
    if v>0:
        u += 1
print(u)

Submission status: Accepted

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

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()))
    s = 0

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

    if s > -C:
        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):
    A.append(list(map(int, input().split())))
total = 0
cnt = 0

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

print(cnt)

Submission status: Accepted

Solution code:
import numpy as np
n, m, c = map(int, input().strip().split())
bs = np.array(list(map(int, input().strip().split())))
as_ = np.array([list(map(int, input().strip().split())) for _ in range(n)])

result = np.dot(as_, bs) + c
counts = np.ones_like(result)
ans = np.sum(counts[result > 0])

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)]
count = 0
cal = 0
for i in range(N):
    for k in range(M):
        cal += A[i][k]*B[k]
    if cal + C > 0:
        count += 1
        cal = 0
    else: 
    	cal =0
print(count)

Submission status: Accepted

Solution code:
def prod(a,b,c,m):
  ans=c
  for i in range(m):
    ans+=a[i]*b[i]
  return ans
n,m,c=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):
  if prod(a[i],b,c,m)>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 = np.array([list(map(int, input().split())) for _ in range(N)])

ans = 0

for i in range(N):
    if sum(B * A[i]) + 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()))
    solve = c

    for j in range(m):
        solve += A[j]*B[j]
        
        if j == m-1 and solve > 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)]
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()))
a = [list(map(int,input().split())) for i in range(n)]
ans = 0
x = 0
for code in a:
    x+=sum([b[k]*i for k,i in zip(range(m),code)])
    if x+c>0:
        ans+=1
    x=0
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)]
ans = 0
x = 0
for code in a:
    for k,i in zip(range(m),code):
        x+=(b[k]*i)
    if x+c>0:
        ans+=1
    x=0
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)]
num = 0
for i in range(n):
    d = c
    for j in range(m):
        d += A[i][j]*B[j]
    if d > 0:
        num += 1
print(num)

Submission status: Accepted

Solution code:
# abc121_b.py
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()))
    ans = 0
    for j in range(M):
        ans += A[j]*B[j]
    ans += C
    if ans > 0:
        cnt += 1
print(cnt)

Submission status: Accepted

Solution code:
import numpy as np
n, m, c = map(int, input().split())
li = list(map(int, input().split()))
s_li = [list(map(int, input().split())) for i in range(n)]
array1 = np.array(li)
array2 = np.array(s_li)
ans = 0
for j in range(n):
    if sum(array1 * array2[j]) + c > 0:
        ans += 1

print(ans)

Submission status: Accepted

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

def f(x,y):
  return sum(i*j for i,j in zip(x,y))

count = 0
for i in range(N):
  ary1 = list(map(int,input().split()))
  if f(ary1,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
s=0
for i in range(N):
    A=list(map(int,input().split()))
    for (j,a) in enumerate(A):
        s+=B[j]*a
    if s+C>0:
        cnt+=1
    s=0
print(cnt)

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()))
    tmp = 0
    for j in range(m):
        tmp += a[j]*b[j]
    tmp += c
    if tmp > 0: ans += 1
print(ans)

Submission status: Accepted

Solution code:
import numpy as np
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()))
  tmp = C
  for j in range(M):
    tmp += A[j]*B[j]
  if tmp>0:
    ans += 1
print(ans)

Submission status: Accepted

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

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

print(count)

Submission status: Accepted

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

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

print(count)

Submission status: Accepted

Solution code:
N, M, C = map(int, input().split())
B = list(map(int, input().split()))
a = 0
sum = 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:
        a += 1
        sum = 0
    else :
        sum = 0
print(a)

Submission status: Accepted

Solution code:
n, m, c = map(int, input().split())
b = list(map(int, input().split()))
counter = 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:
        counter += 1
print(counter)

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
total = 0
r_cnt = 0
while n > 0:
    for i in range(m):
        total += b[i]*a[r_cnt][i]
    if total + c > 0:
        ans += 1
    total = 0
    r_cnt += 1
    n -= 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)]
a = 0
sum = 0
for i in range(N):
    for j in range(M):
        sum += A[i][j] * B[j]
    if sum + C > 0:
        a += 1
        sum = 0
    else :
        sum = 0
print(a)

Submission status: Accepted

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

Submission status: Accepted

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

res = 0
for _ in range(n):
    al = list(map(int, input().split()))
    s = c + sum([al[i]*bl[i] for i in range(m)])
    if s>0:
        res += 1
print(res)

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)]
ans = 0
for i in a:
    cnt = c
    for j in range(m):
        cnt += i[j] * b[j]
    if cnt > 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 = np.array([list(map(int,list(input().split()))) for i in range(N)])
 
ans = 0
for i in range(N):
    val = np.sum(A[i, :] * B) + C
    if val > 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()))
    s = sum(map(lambda x, y: x * y, a, b)) + c
    if s > 0:
        ans += 1

print(ans)

Submission status: Accepted

Solution code:
import numpy as np
import sys

n, m, c = map(int, input().split())
b = np.array([int(x) for x in input().split()])
ans = 0
for _ in range(n):
	a = np.array([int(x) for x in input().split()])
	a *= b
	if np.sum(a) + 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 i in range(N)]

count = 0
for x in range(N):
    A_check = A[x]
    sumNum = 0
    for y in range(M):
        sumNum += A_check[y] * B[y]
    sumNum += C
    if sumNum > 0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
from operator import mul

# 自分の解答
def myAnswer(B:list,A:list,C:int) -> int:
   counter=0
   for a in A:
      if( sum(map(mul,B,a)) + C > 0): counter += 1
   return counter


def modelAnswer(B:list,A:list,C:int,N:int,M:int) -> int:
   ans = 0
   for i in range(N):
      total = 0
      for j in range(M):
         total += A[i][j] * B[j]
      if(total + C > 0): ans += 1
   return ans


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

   ans = myAnswer(B[:],A[:],C)
   ans2 = modelAnswer(B[:],A[:],C,N,M)
   print(ans2)


if __name__ == '__main__':
   main()

Submission status: Accepted

Solution code:
'''
difficult   　: 
ペナルティ　  　:分
実際の回答時間  :分
WAの回数　     :回
合計時間　　  　:分
'''
from operator import mul
def myAnswer(B:list,A:list,C:int) -> int:
   counter=0
   for a in A:
      if( sum(map(mul,B,a)) + C > 0):
         counter += 1
   return counter




def modelAnswer():
   tmp=1
def main():
   N,M,C = map(int,input().split())
   B = list(map(int,input().split()))
   A=[]
   for _ in range(N):
      A.append(list(map(int,input().split())))
      
   ans = myAnswer(B[:],A[:],C)
   print((ans))


if __name__ == '__main__':
   main()

Submission status: Accepted

Solution code:
N,M,C = map(int,input().split())
B = input().split()
B = [int(x) for x in B]
Ans = 0
for _ in range(N):
  A = input().split()
  s = C
  for j in range(M):
    s += int(A[j])*B[j]
  if s > 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):
    A.append(input().split())
count = 0
for i in range(N):
    r = C
    for j in range(M):
        r += int(A[i][j]) * B[j]
    if r > 0:
        count += 1
print(count)

Submission status: Accepted

Solution code:
import math
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
for j in range(N):
    judge=C
    for i in range(M):
        judge+=A[j][i]*B[i]
    if judge>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 = []
for _ in range(n):
    A.append(list(map(int,input().split())))

             
a = np.array(A)
ans = 0
for i in range(n):
    k = c + sum(B *a[i])
    if k >0:
        ans+= 1
print(ans)

Submission status: Accepted

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

ans=0
for i in range(N):
    ans+=1*(sum(a*b for a,b in zip(map(int,input().split()),B))+C>0)

print(ans)

Submission status: Accepted

Solution code:
import sys
import numpy as np

sys.setrecursionlimit(10 ** 6)
int1 = lambda x: int(x) - 1
printV = lambda x: print(*x, sep="\n")
printH = lambda x: print(" ".join(map(str,x)))
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,m,c = MI()
	b = np.array(LI())
	ans = 0
	for _ in range(n):
		a = np.array(LI())
		if np.sum(a*b)+c > 0:
			ans+=1
	print(ans)


if __name__ == '__main__':
	main()

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()))
    s = C
    for j in range(M):
        s += A[j] * B[j]
    if s > 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
i = 0
while i < n:
    A = list(map(int, input().split(' ')))
    j = 0
    q = c
    while j < m:
        q += (B[j]*A[j])
        j += 1
    if q > 0:
        ans += 1
    i += 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)]
count = 0
for i in range(n):
    x = 0
    for j in range(m):
        x += a[i][j]*b[j]
    
    if (x+c > 0):
        count += 1
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()))
  if C + sum(A[j] * B[j] for j in range(M)) > 0:
    ans += 1

print(ans)

Submission status: Accepted

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

Submission status: Accepted

Solution code:
n,m,c =map(int ,input().split())
b =list(map(int ,input().split()))
a =[]
count =0
for i in range(n):
    a.append(list(map(int, input().split())))
for i in range(n):
    ans =0
    for j in range(m):
        ans +=a[i][j]*b[j]
    if ans +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 = [list(map(int,input().split())) for _ in range(N)]

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=[0]*m
a=[0]*n
ans=0
b=list(map(int,input().split()))
for i in range(n):
  a[i]=[0]*m
  a[i]=list(map(int,input().split()))
  size=0
  for j in range(m):
    size+=b[j]*a[i][j]
  size+=c
  if (size>0):
    ans+=1

print(ans)

Submission status: Accepted

Solution code:
n,m,c=[int(i) for i in 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()]
    total=c
    for j in range(m):
        total+=a[j]*b[j]
    if total>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)]
e=0
for i in range(n):
    d=0
    for j in range(m):
        d+=a[i][j]*b[j]
    if d+c>0:
        e+=1
print(e)

Submission status: Accepted

Solution code:
n,m,c=list(map(int,input().split()))
b=list(map(int,input().split()))
ans=0
for i in range(n):
  tmp=0
  a=list(map(int,input().split()))
  for j in range(m):
    tmp+=b[j]*a[j]
  if tmp>-c:
    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)]
ans = 0
for a in A:
  check = c
  for i,j in zip(a,b):
    check += i*j
  ans += (check > 0)
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):
  if np.dot(np.array(list(map(int,input().split()))),b)+c > 0:
    ans += 1
print(ans)

Submission status: Accepted

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