Guest User

Untitled

a guest
Sep 18th, 2018
84
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.32 KB | None | 0 0
  1. # coding: utf-8
  2. # Your code here!
  3.  
  4. # ITP1_6_D
  5.  
  6. matrix=list()
  7. col=list()
  8. y,x=map(int,input().split())
  9.  
  10. for _ in range(y):
  11. matrix.append(list(map(int,input().split())))
  12.  
  13. for _ in range(x):
  14. col.append(int(input()))
  15.  
  16. for j in range(y):
  17. result=0
  18. for i in range(x):
  19. result+=matrix[j][i]*col[i]
  20. print(result)
Add Comment
Please, Sign In to add comment