import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {

  public static void main(String[] args) throws IOException {
    
    BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
    String[] inputRowAndCol = (input.readLine()).split("\\s");
    int x = Integer.parseInt(inputRowAndCol[0]);
    int y = Integer.parseInt(inputRowAndCol[1]);

 
    int[][] a = new int[x][y];
    String[] b = null; 
    
    for (int i = 0; i < x; i++) {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    }
   
    int[] vectorB = new int[y];
    for (int k = 0; k < y; k++) {
      vectorB[k] = Integer.parseInt(input.readLine());
    }

    for (int l = 0; l < x; l++) {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    }
  }
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStreamReader; InputStreamReader java.io public class Main {

  public static void main(String[] args) throws IOException {
    
    BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
    String[] inputRowAndCol = (input.readLine()).split("\\s");
    int x = Integer.parseInt(inputRowAndCol[0]);
    int y = Integer.parseInt(inputRowAndCol[1]);

 
    int[][] a = new int[x][y];
    String[] b = null; 
    
    for (int i = 0; i < x; i++) {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    }
   
    int[] vectorB = new int[y];
    for (int k = 0; k < y; k++) {
      vectorB[k] = Integer.parseInt(input.readLine());
    }

    for (int l = 0; l < x; l++) {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    }
  }
} Main public static void main(String[] args) throws IOException {
    
    BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
    String[] inputRowAndCol = (input.readLine()).split("\\s");
    int x = Integer.parseInt(inputRowAndCol[0]);
    int y = Integer.parseInt(inputRowAndCol[1]);

 
    int[][] a = new int[x][y];
    String[] b = null; 
    
    for (int i = 0; i < x; i++) {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    }
   
    int[] vectorB = new int[y];
    for (int k = 0; k < y; k++) {
      vectorB[k] = Integer.parseInt(input.readLine());
    }

    for (int l = 0; l < x; l++) {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    }
  } main {
    
    BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
    String[] inputRowAndCol = (input.readLine()).split("\\s");
    int x = Integer.parseInt(inputRowAndCol[0]);
    int y = Integer.parseInt(inputRowAndCol[1]);

 
    int[][] a = new int[x][y];
    String[] b = null; 
    
    for (int i = 0; i < x; i++) {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    }
   
    int[] vectorB = new int[y];
    for (int k = 0; k < y; k++) {
      vectorB[k] = Integer.parseInt(input.readLine());
    }

    for (int l = 0; l < x; l++) {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    }
  } BufferedReader input = new BufferedReader(new InputStreamReader(System.in)); input new BufferedReader(new InputStreamReader(System.in)) String[] inputRowAndCol = (input.readLine()).split("\\s"); inputRowAndCol (input.readLine()).split("\\s") (input.readLine()).split (input.readLine()) input.readLine input "\\s" int x = Integer.parseInt(inputRowAndCol[0]); x Integer.parseInt(inputRowAndCol[0]) Integer.parseInt Integer inputRowAndCol[0] inputRowAndCol 0 int y = Integer.parseInt(inputRowAndCol[1]); y Integer.parseInt(inputRowAndCol[1]) Integer.parseInt Integer inputRowAndCol[1] inputRowAndCol 1 int[][] a = new int[x][y]; a new int[x][y] x y String[] b = null; b null for (int i = 0; i < x; i++) {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    } int i = 0; int i = 0; i 0 i < x i x i++ i++ i {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    } {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    } b = (input.readLine()).split("\\s") b (input.readLine()).split("\\s") (input.readLine()).split (input.readLine()) input.readLine input "\\s" for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      } int j = 0; int j = 0; j 0 j < y j y j++ j++ j {
        
       a[i][j] = Integer.parseInt(b[j]);
      } {
        
       a[i][j] = Integer.parseInt(b[j]);
      } a[i][j] = Integer.parseInt(b[j]) a[i][j] a[i] a i j Integer.parseInt(b[j]) Integer.parseInt Integer b[j] b j int[] vectorB = new int[y]; vectorB new int[y] y for (int k = 0; k < y; k++) {
      vectorB[k] = Integer.parseInt(input.readLine());
    } int k = 0; int k = 0; k 0 k < y k y k++ k++ k {
      vectorB[k] = Integer.parseInt(input.readLine());
    } {
      vectorB[k] = Integer.parseInt(input.readLine());
    } vectorB[k] = Integer.parseInt(input.readLine()) vectorB[k] vectorB k Integer.parseInt(input.readLine()) Integer.parseInt Integer input.readLine() input.readLine input for (int l = 0; l < x; l++) {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    } int l = 0; int l = 0; l 0 l < x l x l++ l++ l {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    } {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    } int result = 0; result 0 for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      } int m = 0; int m = 0; m 0 m < y m y m++ m++ m {
       
        result += (a[l][m] * vectorB[m]);
      } {
       
        result += (a[l][m] * vectorB[m]);
      } result += (a[l][m] * vectorB[m]) result (a[l][m] * vectorB[m]) a[l][m] a[l] a l m vectorB[m] vectorB m System.out.println(result) System.out.println System.out System System.out result String[] args args public class Main {

  public static void main(String[] args) throws IOException {
    
    BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
    String[] inputRowAndCol = (input.readLine()).split("\\s");
    int x = Integer.parseInt(inputRowAndCol[0]);
    int y = Integer.parseInt(inputRowAndCol[1]);

 
    int[][] a = new int[x][y];
    String[] b = null; 
    
    for (int i = 0; i < x; i++) {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    }
   
    int[] vectorB = new int[y];
    for (int k = 0; k < y; k++) {
      vectorB[k] = Integer.parseInt(input.readLine());
    }

    for (int l = 0; l < x; l++) {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    }
  }
} public class Main {

  public static void main(String[] args) throws IOException {
    
    BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
    String[] inputRowAndCol = (input.readLine()).split("\\s");
    int x = Integer.parseInt(inputRowAndCol[0]);
    int y = Integer.parseInt(inputRowAndCol[1]);

 
    int[][] a = new int[x][y];
    String[] b = null; 
    
    for (int i = 0; i < x; i++) {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    }
   
    int[] vectorB = new int[y];
    for (int k = 0; k < y; k++) {
      vectorB[k] = Integer.parseInt(input.readLine());
    }

    for (int l = 0; l < x; l++) {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    }
  }
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStreamReader;

public class Main {

  public static void main(String[] args) throws IOException {
    
    BufferedReader input = new BufferedReader(new InputStreamReader(System.in));
    String[] inputRowAndCol = (input.readLine()).split("\\s");
    int x = Integer.parseInt(inputRowAndCol[0]);
    int y = Integer.parseInt(inputRowAndCol[1]);

 
    int[][] a = new int[x][y];
    String[] b = null; 
    
    for (int i = 0; i < x; i++) {
     
      b = (input.readLine()).split("\\s");
     
      for (int j = 0; j < y; j++) {
        
       a[i][j] = Integer.parseInt(b[j]);
      }
    }
   
    int[] vectorB = new int[y];
    for (int k = 0; k < y; k++) {
      vectorB[k] = Integer.parseInt(input.readLine());
    }

    for (int l = 0; l < x; l++) {
      int result = 0; 
    
      for (int m = 0; m < y; m++) {
       
        result += (a[l][m] * vectorB[m]);
      }
      
      System.out.println(result);
    }
  }
}
