Problem: 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.

Submission attempts (in order):
import numpy as np
N,M,C = map(int,input().split())
B = [int(k) for k in input().split()]
A = [[int(j) for j in input().split()] for i in range(1,N+1)] 
b = np.array(B)
cnt = 0
for i in range(1,N+1):
    if (np.dot(np.array(A[i]),b) + C >0):
        cnt += 1
    else:
        cnt = cnt
        
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = list(int,input().split())
for i in range(1,N)
    Ai = list(int,input().split())
    

ai = np.array(Ai)
b = np.array(B)

ait = ai.reshape([N,1])
cnt = 0
for i in range(1,N)
    if (np.dot(ait,b) + C >0)
         cnt += 1
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = list(int,input().split())
for i in range(1,N)
    Ai = list(int,input().split())
    ai = np.array(Ai)
b = np.array(B)
bt = b.reshape([N,1])
cnt = 0
for i in range(1,N)
    if (np.dot(ai,bt) + C >0)
         cnt += 1
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int,input().split()]
for i in range(1,N)
    Ai = [int(j) for j in input().split()]
    ai = np.array(Ai)   
b = np.array(B)
bt = b.reshape([N,1])
cnt = 0
for i in range(1,N)
    if (np.dot(ai,bt) + C >0)
         cnt += 1
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int,input().split()]
for i in range(1,N)
    Ai = [int,input().split()]
    ai = np.array(Ai)   
b = np.array(B)
bt = b.reshape([N,1])
cnt = 0
for i in range(1,N)
    if (np.dot(ai,bt) + C >0)
         cnt += 1
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int(k) for k in input().split()]
for i in range(1,N):
    Ai = [int(j) for j in input().split()]
    ai = np.array(Ai)   
b = np.array(B)
bt = b.reshape([M,1])
cnt = 0
for i in range(1,N):
    if (np.dot(ai,bt) + C >0):
        cnt += 1
    else:
        cnt = cnt
        
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int,input().split()]
for i in range(1,N):
    Ai = [int(j) for j in input().split()]
    ai = np.array(Ai)   
b = np.array(B)
bt = b.reshape([M,1])
cnt = 0
for i in range(1,N)
    if (np.dot(ai,bt) + C >0)
         cnt += 1
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int(k) for k in input().split()]
for i in range(1,N):
    Ai = [int(j) for j in input().split()]
    ai = np.array(Ai)   
b = np.array(B)
bt = b.reshape([M,1])
cnt = 0
for i in range(1,N):
    if (np.dot(ai,bt) + C >0):
         cnt += 1
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int(k) for k in input().split()]
A = [[int(j) for j in input().split()] for i in range(1,N+1)] 
b = np.array(B)
a = np.array(A)
cnt = 0
for i in range(1,N+1):
    if (np.dot(a[i],b) + C >0):
        cnt += 1
    else:
        cnt = cnt
        
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int(k) for k in input().split()]
for i in range(1,N+1):
    Ai = [int(j) for j in input().split()]
    ai = np.array(Ai)   
b = np.array(B)
cnt = 0
for i in range(1,N+1):
    if (np.dot(ai,b) + C >0):
        cnt += 1
    else:
        cnt = cnt
        
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int(k) for k in input().split()]
A = [[int(j) for j in input().split()] for i in range(1,N)] 
b = np.array(B)
a = np.array(A)
cnt = 0
for i in range(1,N):
    if (np.dot(a[i],b) + C >0):
        cnt += 1
    else:
        cnt = cnt
        
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int(k) for k in input().split()]
for i in range(1,N):
    Ai = [int(j) for j in input().split()]
    ai = np.array(Ai)   
b = np.array(B)
cnt = 0
for i in range(1,N):
    if (np.dot(ai,b) + C >0):
        cnt += 1
    else:
        cnt = cnt
        
print(cnt)




import numpy as np
N,M,C = map(int,input().split())
B = [int(k) for k in input().split()]
A = [[int(j) for j in input().split()] for i in range(N)] 
b = np.array(B)
cnt = 0
for i in range(N):
    if (np.dot(np.array(A[i]),b) + C >0):
        cnt += 1
    else:
        cnt = cnt
        
print(cnt)




Verdicts: Runtime Error

Runtime Error

Runtime Error

Runtime Error

Runtime Error

Wrong Answer

Runtime Error

Wrong Answer

Runtime Error

Wrong Answer

Runtime Error

Wrong Answer

Accepted