You are viewing a single comment's thread. Return to all comments →
import numpy
N = int(input())
ListA = list() ListB = list()
for i in range(N): ListA.append(list(map(int , input().split())))
for j in range(N): ListB.append(list(map(int , input().split())))
A = numpy.array(ListA) B = numpy.array(ListB)
result = numpy.dot(A , B)
print(result)
Seems like cookies are disabled on this browser, please enable them to open this website
Dot and Cross
You are viewing a single comment's thread. Return to all comments →
import numpy
N = int(input())
ListA = list() ListB = list()
for i in range(N): ListA.append(list(map(int , input().split())))
for j in range(N): ListB.append(list(map(int , input().split())))
A = numpy.array(ListA) B = numpy.array(ListB)
result = numpy.dot(A , B)
print(result)