import java.io.*;
import java.util.Arrays;

public class Main{
	public static void main(String[] args) throws IOException{ 
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String line1 = br.readLine();
		String[] sp1 = line1.split(" ");
		int n = Integer.parseInt(sp1[0]);
		int m = Integer.parseInt(sp1[1]);
		int[][] a = new int[n][m];
		int[] b = new int[m];
		for (int i = 0; i<n  ; i++) {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		}
		for (int i=0 ; i<m ;i++ ) {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		}
		int[] c = new int[n];
		for (int i=0 ; i<n ; i++) {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		}
		for (int youso : c) {
			System.out.println(youso);
		}
	}

} import java.io.*; io.* java import java.util.Arrays; Arrays java.util public class Main{
	public static void main(String[] args) throws IOException{ 
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String line1 = br.readLine();
		String[] sp1 = line1.split(" ");
		int n = Integer.parseInt(sp1[0]);
		int m = Integer.parseInt(sp1[1]);
		int[][] a = new int[n][m];
		int[] b = new int[m];
		for (int i = 0; i<n  ; i++) {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		}
		for (int i=0 ; i<m ;i++ ) {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		}
		int[] c = new int[n];
		for (int i=0 ; i<n ; i++) {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		}
		for (int youso : c) {
			System.out.println(youso);
		}
	}

} Main public static void main(String[] args) throws IOException{ 
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String line1 = br.readLine();
		String[] sp1 = line1.split(" ");
		int n = Integer.parseInt(sp1[0]);
		int m = Integer.parseInt(sp1[1]);
		int[][] a = new int[n][m];
		int[] b = new int[m];
		for (int i = 0; i<n  ; i++) {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		}
		for (int i=0 ; i<m ;i++ ) {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		}
		int[] c = new int[n];
		for (int i=0 ; i<n ; i++) {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		}
		for (int youso : c) {
			System.out.println(youso);
		}
	} main { 
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String line1 = br.readLine();
		String[] sp1 = line1.split(" ");
		int n = Integer.parseInt(sp1[0]);
		int m = Integer.parseInt(sp1[1]);
		int[][] a = new int[n][m];
		int[] b = new int[m];
		for (int i = 0; i<n  ; i++) {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		}
		for (int i=0 ; i<m ;i++ ) {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		}
		int[] c = new int[n];
		for (int i=0 ; i<n ; i++) {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		}
		for (int youso : c) {
			System.out.println(youso);
		}
	} BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String line1 = br.readLine(); line1 br.readLine() br.readLine br String[] sp1 = line1.split(" "); sp1 line1.split(" ") line1.split line1 " " int n = Integer.parseInt(sp1[0]); n Integer.parseInt(sp1[0]) Integer.parseInt Integer sp1[0] sp1 0 int m = Integer.parseInt(sp1[1]); m Integer.parseInt(sp1[1]) Integer.parseInt Integer sp1[1] sp1 1 int[][] a = new int[n][m]; a new int[n][m] n m int[] b = new int[m]; b new int[m] m for (int i = 0; i<n  ; i++) {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		} int i = 0; int i = 0; i 0 i<n i n i++ i++ i {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		} {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		} String line = br.readLine(); line br.readLine() br.readLine br String[] str = line.split(" "); str line.split(" ") line.split line " " for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			} int j=0; int j=0; j 0 j<m j m j++ j++ j {
				a[i][j] = Integer.parseInt(str[j]);
			} {
				a[i][j] = Integer.parseInt(str[j]);
			} a[i][j] = Integer.parseInt(str[j]) a[i][j] a[i] a i j Integer.parseInt(str[j]) Integer.parseInt Integer str[j] str j for (int i=0 ; i<m ;i++ ) {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		} int i=0 ; int i=0 ; i 0 i<m i m i++ i++ i {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		} {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		} String line = br.readLine(); line br.readLine() br.readLine br b[i] = Integer.parseInt(line) b[i] b i Integer.parseInt(line) Integer.parseInt Integer line int[] c = new int[n]; c new int[n] n for (int i=0 ; i<n ; i++) {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		} int i=0 ; int i=0 ; i 0 i<n i n i++ i++ i {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		} {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		} for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			} int j = 0; int j = 0; j 0 j<m j m j++ j++ j {
				c[i] += (a[i][j] * b[j]); 
			} {
				c[i] += (a[i][j] * b[j]); 
			} c[i] += (a[i][j] * b[j]) c[i] c i (a[i][j] * b[j]) a[i][j] a[i] a i j b[j] b j for (int youso : c) {
			System.out.println(youso);
		} int youso c {
			System.out.println(youso);
		} {
			System.out.println(youso);
		} System.out.println(youso) System.out.println System.out System System.out youso String[] args args public class Main{
	public static void main(String[] args) throws IOException{ 
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String line1 = br.readLine();
		String[] sp1 = line1.split(" ");
		int n = Integer.parseInt(sp1[0]);
		int m = Integer.parseInt(sp1[1]);
		int[][] a = new int[n][m];
		int[] b = new int[m];
		for (int i = 0; i<n  ; i++) {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		}
		for (int i=0 ; i<m ;i++ ) {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		}
		int[] c = new int[n];
		for (int i=0 ; i<n ; i++) {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		}
		for (int youso : c) {
			System.out.println(youso);
		}
	}

} public class Main{
	public static void main(String[] args) throws IOException{ 
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String line1 = br.readLine();
		String[] sp1 = line1.split(" ");
		int n = Integer.parseInt(sp1[0]);
		int m = Integer.parseInt(sp1[1]);
		int[][] a = new int[n][m];
		int[] b = new int[m];
		for (int i = 0; i<n  ; i++) {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		}
		for (int i=0 ; i<m ;i++ ) {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		}
		int[] c = new int[n];
		for (int i=0 ; i<n ; i++) {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		}
		for (int youso : c) {
			System.out.println(youso);
		}
	}

} Main
import java.io.*;
import java.util.Arrays;

public class Main{
	public static void main(String[] args) throws IOException{ 
		BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
		String line1 = br.readLine();
		String[] sp1 = line1.split(" ");
		int n = Integer.parseInt(sp1[0]);
		int m = Integer.parseInt(sp1[1]);
		int[][] a = new int[n][m];
		int[] b = new int[m];
		for (int i = 0; i<n  ; i++) {
			String line = br.readLine();
			String[] str = line.split(" ");
			for (int j=0; j<m ; j++ ) {
				a[i][j] = Integer.parseInt(str[j]);
			}
		}
		for (int i=0 ; i<m ;i++ ) {
			String line = br.readLine();
			b[i] = Integer.parseInt(line);
		}
		int[] c = new int[n];
		for (int i=0 ; i<n ; i++) {
			for (int j = 0; j<m ; j++) {
				c[i] += (a[i][j] * b[j]); 
			}
		}
		for (int youso : c) {
			System.out.println(youso);
		}
	}

}