import java.util.Scanner;

/**
 * HJ69 矩阵乘法 - 中等
 */
public class HJ069 {
    public static void main(String[] args) {
        Scanner sc = new Scanner(System.in);
        while (sc.hasNext()) {
            int x = sc.nextInt();
            int y = sc.nextInt();
            int z = sc.nextInt();
            int[][] xy = new int[x][y];
            int[][] yz = new int[y][z];
            int[][] xz = new int[x][z];
            for (int i = 0; i < x; i++) {
                for (int j = 0; j < y; j++) {
                    xy[i][j] = sc.nextInt();
                }
            }
            for (int i = 0; i < y; i++) {
                for (int j = 0; j < z; j++) {
                    yz[i][j] = sc.nextInt();
                }
            }
            for (int i = 0; i < x; i++) {
                for (int j = 0; j < z; j++) {
                    for (int k = 0; k < y; k++) {
                        xz[i][j] = xz[i][j] + xy[i][k] * yz[k][j];
                    }
                }
            }
            for (int i = 0; i < x; i++) {
                for (int j = 0; j < z; j++) {
                    System.out.print(xz[i][j] + " ");
                }
                System.out.println();
            }
        }
        sc.close();
    }

}