import java.util.*;

public class Main {
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);

		//???, ?????\??????????????????
		int n = sc.nextInt();
		int m = sc.nextInt();
		int matrixA[][] = new int[m][n];
		int vectorB[] = new int[m];
		int vectorC[] = new int[n];
		
		//??????A????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		}
		
		//????????????b????????????????´?
		for(int j = 0; j < m; j++) {
			vectorB[j] = sc.nextInt();
		}
		
		//????????????c????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		}
		
		for(int i = 0; i < n; i++) {
			System.out.println(vectorC[i]);
		}
	}
} import java.util.*; util.* java public class Main {
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);

		//???, ?????\??????????????????
		int n = sc.nextInt();
		int m = sc.nextInt();
		int matrixA[][] = new int[m][n];
		int vectorB[] = new int[m];
		int vectorC[] = new int[n];
		
		//??????A????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		}
		
		//????????????b????????????????´?
		for(int j = 0; j < m; j++) {
			vectorB[j] = sc.nextInt();
		}
		
		//????????????c????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		}
		
		for(int i = 0; i < n; i++) {
			System.out.println(vectorC[i]);
		}
	}
} Main public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);

		//???, ?????\??????????????????
		int n = sc.nextInt();
		int m = sc.nextInt();
		int matrixA[][] = new int[m][n];
		int vectorB[] = new int[m];
		int vectorC[] = new int[n];
		
		//??????A????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		}
		
		//????????????b????????????????´?
		for(int j = 0; j < m; j++) {
			vectorB[j] = sc.nextInt();
		}
		
		//????????????c????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		}
		
		for(int i = 0; i < n; i++) {
			System.out.println(vectorC[i]);
		}
	} main {
		
		Scanner sc = new Scanner(System.in);

		//???, ?????\??????????????????
		int n = sc.nextInt();
		int m = sc.nextInt();
		int matrixA[][] = new int[m][n];
		int vectorB[] = new int[m];
		int vectorC[] = new int[n];
		
		//??????A????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		}
		
		//????????????b????????????????´?
		for(int j = 0; j < m; j++) {
			vectorB[j] = sc.nextInt();
		}
		
		//????????????c????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		}
		
		for(int i = 0; i < n; i++) {
			System.out.println(vectorC[i]);
		}
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int m = sc.nextInt(); m sc.nextInt() sc.nextInt sc int matrixA[][] = new int[m][n]; matrixA new int[m][n] m n int vectorB[] = new int[m]; vectorB new int[m] m int vectorC[] = new int[n]; vectorC new int[n] n for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		} {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		} for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			} int j = 0; int j = 0; j 0 j < m j m j++ j++ j {
				matrixA[j][i] = sc.nextInt();
			} {
				matrixA[j][i] = sc.nextInt();
			} matrixA[j][i] = sc.nextInt() matrixA[j][i] matrixA[j] matrixA j i sc.nextInt() sc.nextInt sc for(int j = 0; j < m; j++) {
			vectorB[j] = sc.nextInt();
		} int j = 0; int j = 0; j 0 j < m j m j++ j++ j {
			vectorB[j] = sc.nextInt();
		} {
			vectorB[j] = sc.nextInt();
		} vectorB[j] = sc.nextInt() vectorB[j] vectorB j sc.nextInt() sc.nextInt sc for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		} {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		} for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			} int j = 0; int j = 0; j 0 j < m j m j++ j++ j {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			} {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			} vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j] vectorC[i] vectorC i vectorC[i] + matrixA[j][i] * vectorB[j] vectorC[i] vectorC i matrixA[j][i] * vectorB[j] matrixA[j][i] matrixA[j] matrixA j i vectorB[j] vectorB j for(int i = 0; i < n; i++) {
			System.out.println(vectorC[i]);
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			System.out.println(vectorC[i]);
		} {
			System.out.println(vectorC[i]);
		} System.out.println(vectorC[i]) System.out.println System.out System System.out vectorC[i] vectorC i String[] args args public class Main {
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);

		//???, ?????\??????????????????
		int n = sc.nextInt();
		int m = sc.nextInt();
		int matrixA[][] = new int[m][n];
		int vectorB[] = new int[m];
		int vectorC[] = new int[n];
		
		//??????A????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		}
		
		//????????????b????????????????´?
		for(int j = 0; j < m; j++) {
			vectorB[j] = sc.nextInt();
		}
		
		//????????????c????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		}
		
		for(int i = 0; i < n; i++) {
			System.out.println(vectorC[i]);
		}
	}
} public class Main {
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);

		//???, ?????\??????????????????
		int n = sc.nextInt();
		int m = sc.nextInt();
		int matrixA[][] = new int[m][n];
		int vectorB[] = new int[m];
		int vectorC[] = new int[n];
		
		//??????A????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		}
		
		//????????????b????????????????´?
		for(int j = 0; j < m; j++) {
			vectorB[j] = sc.nextInt();
		}
		
		//????????????c????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		}
		
		for(int i = 0; i < n; i++) {
			System.out.println(vectorC[i]);
		}
	}
} Main
import java.util.*;

public class Main {
	public static void main(String[] args) {
		
		Scanner sc = new Scanner(System.in);

		//???, ?????\??????????????????
		int n = sc.nextInt();
		int m = sc.nextInt();
		int matrixA[][] = new int[m][n];
		int vectorB[] = new int[m];
		int vectorC[] = new int[n];
		
		//??????A????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				matrixA[j][i] = sc.nextInt();
			}
		}
		
		//????????????b????????????????´?
		for(int j = 0; j < m; j++) {
			vectorB[j] = sc.nextInt();
		}
		
		//????????????c????????????????´?
		for(int i = 0; i < n; i++) {
			for(int j = 0; j < m; j++) {
				vectorC[i] = vectorC[i] + matrixA[j][i] * vectorB[j];
			}
		}
		
		for(int i = 0; i < n; i++) {
			System.out.println(vectorC[i]);
		}
	}
}