// ITP1_6_D Matrix Vector Multiplication
import java.io.*;

public class Main {
   public static void main(String[] args) {
      try {
         BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
         String[] strAry1 = (br.readLine()).split(" ");
         int n = Integer.parseInt(strAry1[0]);
         int m = Integer.parseInt(strAry1[1]);
         int[][] A = new int[n][m];
         int[] b = new int[m];
         int[] c = new int[n];

         for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         }

         for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         }

         for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         }

         for (int result : c)
            System.out.printf("%d\n", result);
      }

      catch (Exception e) {
         System.err.println(e);
      }
   }
} import java.io.*; io.* java public class Main {
   public static void main(String[] args) {
      try {
         BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
         String[] strAry1 = (br.readLine()).split(" ");
         int n = Integer.parseInt(strAry1[0]);
         int m = Integer.parseInt(strAry1[1]);
         int[][] A = new int[n][m];
         int[] b = new int[m];
         int[] c = new int[n];

         for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         }

         for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         }

         for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         }

         for (int result : c)
            System.out.printf("%d\n", result);
      }

      catch (Exception e) {
         System.err.println(e);
      }
   }
} Main public static void main(String[] args) {
      try {
         BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
         String[] strAry1 = (br.readLine()).split(" ");
         int n = Integer.parseInt(strAry1[0]);
         int m = Integer.parseInt(strAry1[1]);
         int[][] A = new int[n][m];
         int[] b = new int[m];
         int[] c = new int[n];

         for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         }

         for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         }

         for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         }

         for (int result : c)
            System.out.printf("%d\n", result);
      }

      catch (Exception e) {
         System.err.println(e);
      }
   } main {
      try {
         BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
         String[] strAry1 = (br.readLine()).split(" ");
         int n = Integer.parseInt(strAry1[0]);
         int m = Integer.parseInt(strAry1[1]);
         int[][] A = new int[n][m];
         int[] b = new int[m];
         int[] c = new int[n];

         for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         }

         for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         }

         for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         }

         for (int result : c)
            System.out.printf("%d\n", result);
      }

      catch (Exception e) {
         System.err.println(e);
      }
   } try {
         BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
         String[] strAry1 = (br.readLine()).split(" ");
         int n = Integer.parseInt(strAry1[0]);
         int m = Integer.parseInt(strAry1[1]);
         int[][] A = new int[n][m];
         int[] b = new int[m];
         int[] c = new int[n];

         for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         }

         for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         }

         for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         }

         for (int result : c)
            System.out.printf("%d\n", result);
      }

      catch (Exception e) {
         System.err.println(e);
      } catch (Exception e) {
         System.err.println(e);
      } Exception e {
         System.err.println(e);
      } System.err.println(e) System.err.println System.err System System.err e {
         BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
         String[] strAry1 = (br.readLine()).split(" ");
         int n = Integer.parseInt(strAry1[0]);
         int m = Integer.parseInt(strAry1[1]);
         int[][] A = new int[n][m];
         int[] b = new int[m];
         int[] c = new int[n];

         for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         }

         for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         }

         for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         }

         for (int result : c)
            System.out.printf("%d\n", result);
      } BufferedReader br = new BufferedReader(new InputStreamReader(System.in)); br new BufferedReader(new InputStreamReader(System.in)) String[] strAry1 = (br.readLine()).split(" "); strAry1 (br.readLine()).split(" ") (br.readLine()).split (br.readLine()) br.readLine br " " int n = Integer.parseInt(strAry1[0]); n Integer.parseInt(strAry1[0]) Integer.parseInt Integer strAry1[0] strAry1 0 int m = Integer.parseInt(strAry1[1]); m Integer.parseInt(strAry1[1]) Integer.parseInt Integer strAry1[1] strAry1 1 int[][] A = new int[n][m]; A new int[n][m] n m int[] b = new int[m]; b new int[m] m int[] c = new int[n]; c new int[n] n for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         } int i = 0; int i = 0; i 0 i < A.length i A.length A A.length i++ i++ i {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         } {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         } String[] strAry2 = (br.readLine()).split(" "); strAry2 (br.readLine()).split(" ") (br.readLine()).split (br.readLine()) br.readLine br " " for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            } int j = 0; int j = 0; j 0 j < A[i].length j A[i].length A[i] A i A[i].length j++ j++ j {
               A[i][j] = Integer.parseInt(strAry2[j]);
            } {
               A[i][j] = Integer.parseInt(strAry2[j]);
            } A[i][j] = Integer.parseInt(strAry2[j]) A[i][j] A[i] A i j Integer.parseInt(strAry2[j]) Integer.parseInt Integer strAry2[j] strAry2 j for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         } int i = 0; int i = 0; i 0 i < b.length i b.length b b.length i++ i++ i {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         } {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         } String str = br.readLine(); str br.readLine() br.readLine br b[i] = Integer.parseInt(str) b[i] b i Integer.parseInt(str) Integer.parseInt Integer str for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         } int i = 0; int i = 0; i 0 i < A.length i A.length A A.length i++ i++ i {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         } {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         } for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            } int j = 0; int j = 0; j 0 j < A[i].length j A[i].length A[i] A i A[i].length 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 result : c)
            System.out.printf("%d\n", result); int result c System.out.printf("%d\n", result); System.out.printf("%d\n", result) System.out.printf System.out System System.out "%d\n" result String[] args args public class Main {
   public static void main(String[] args) {
      try {
         BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
         String[] strAry1 = (br.readLine()).split(" ");
         int n = Integer.parseInt(strAry1[0]);
         int m = Integer.parseInt(strAry1[1]);
         int[][] A = new int[n][m];
         int[] b = new int[m];
         int[] c = new int[n];

         for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         }

         for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         }

         for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         }

         for (int result : c)
            System.out.printf("%d\n", result);
      }

      catch (Exception e) {
         System.err.println(e);
      }
   }
} public class Main {
   public static void main(String[] args) {
      try {
         BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
         String[] strAry1 = (br.readLine()).split(" ");
         int n = Integer.parseInt(strAry1[0]);
         int m = Integer.parseInt(strAry1[1]);
         int[][] A = new int[n][m];
         int[] b = new int[m];
         int[] c = new int[n];

         for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         }

         for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         }

         for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         }

         for (int result : c)
            System.out.printf("%d\n", result);
      }

      catch (Exception e) {
         System.err.println(e);
      }
   }
} Main
// ITP1_6_D Matrix Vector Multiplication
import java.io.*;

public class Main {
   public static void main(String[] args) {
      try {
         BufferedReader br = new BufferedReader(new InputStreamReader(System.in));
         String[] strAry1 = (br.readLine()).split(" ");
         int n = Integer.parseInt(strAry1[0]);
         int m = Integer.parseInt(strAry1[1]);
         int[][] A = new int[n][m];
         int[] b = new int[m];
         int[] c = new int[n];

         for (int i = 0; i < A.length; i++) {
            String[] strAry2 = (br.readLine()).split(" ");
            for (int j = 0; j < A[i].length; j++) {
               A[i][j] = Integer.parseInt(strAry2[j]);
            }
         }

         for (int i = 0; i < b.length; i++) {
            String str = br.readLine();
            b[i] = Integer.parseInt(str);
         }

         for (int i = 0; i < A.length; i++) {
            for (int j = 0; j < A[i].length; j++) {
               c[i] += A[i][j] * b[j];
            }
         }

         for (int result : c)
            System.out.printf("%d\n", result);
      }

      catch (Exception e) {
         System.err.println(e);
      }
   }
}