n = map(int,raw_input().strip().split())
a=[[0 for row in range(n[1])] for col in range(n[0])]
for i in range(n[0]):
a[i] = map(int,raw_input().strip().split())
b=[[0 for row in range(n[2])] for col in range(n[1])]
for i in range(n[1]):
b[i] = map(int,raw_input().strip().split())
for i in range(0,n[0]):
for j in range(0,n[2]):
num=0
for k in range(0,n[1]):
num+=a[i][k]*b[k][j]
print num,
print