import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.PrintStream;
import java.io.StreamTokenizer;
import java.util.InputMismatchException;


public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in); 
		Printer pr = new Printer(System.out); 

		int n = sc.nextInt();
		int m = sc.nextInt();
		int l = sc.nextInt();
		
		int[][] a = new int[n][m];
		int[][] b = new int[m][l];

		for (int i = 0; i < n; i++) {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		}
		for (int i = 0; i < m; i++) {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		}

//		int[][] c = new int[n][l];
		for (int i = 0; i < n; i++) {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		}

		pr.close();
		sc.close();
	}

	@SuppressWarnings("unused")
	private static class Scanner {
		InputStreamReader isr;
		BufferedReader br;
		StreamTokenizer st;

		private Scanner() {
		}

		Scanner (InputStream in) {
			isr = new InputStreamReader(in);
			br = new BufferedReader(isr);
			st = new StreamTokenizer(br);
		}

		String next() throws RuntimeException  {
			try {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return st.sval;
		}

		int nextInt() throws RuntimeException {
			try {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return (int)st.nval;
		}

		void close() {
		}
	}

	@SuppressWarnings("unused")
	private static class Printer {
		PrintStream out;
		StringBuffer strbuf;
		int bufSize;
		final String CR;

		Printer(PrintStream out) {
			this.out = out;
			strbuf = new StringBuffer();
			bufSize = 64 * 1024;
			CR = System.getProperty("line.separator");
		}

		void println(String str) {
			strbuf.append(str);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(String str) {
			strbuf.append(str);
			checkStringBuffer();
		}

		void println(int n) {
			strbuf.append(n);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(int n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(long n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(char c) {
			strbuf.append(c);
			checkStringBuffer();
		}

		void printArray(int[] array) {
			for (int i = 0; i < array.length; i++) {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			}
			strbuf.delete(strbuf.length() - 1, strbuf.length());
			strbuf.append(CR);
		}

		void close() {
			flashStringBuffer();
		}

		private void flashStringBuffer() {
			if (strbuf.length() > 0) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}

		private void checkStringBuffer() {
			if (strbuf.length() > bufSize) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}
	}
} import java.io.BufferedReader; BufferedReader java.io import java.io.IOException; IOException java.io import java.io.InputStream; InputStream java.io import java.io.InputStreamReader; InputStreamReader java.io import java.io.PrintStream; PrintStream java.io import java.io.StreamTokenizer; StreamTokenizer java.io import java.util.InputMismatchException; InputMismatchException java.util public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in); 
		Printer pr = new Printer(System.out); 

		int n = sc.nextInt();
		int m = sc.nextInt();
		int l = sc.nextInt();
		
		int[][] a = new int[n][m];
		int[][] b = new int[m][l];

		for (int i = 0; i < n; i++) {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		}
		for (int i = 0; i < m; i++) {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		}

//		int[][] c = new int[n][l];
		for (int i = 0; i < n; i++) {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		}

		pr.close();
		sc.close();
	}

	@SuppressWarnings("unused")
	private static class Scanner {
		InputStreamReader isr;
		BufferedReader br;
		StreamTokenizer st;

		private Scanner() {
		}

		Scanner (InputStream in) {
			isr = new InputStreamReader(in);
			br = new BufferedReader(isr);
			st = new StreamTokenizer(br);
		}

		String next() throws RuntimeException  {
			try {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return st.sval;
		}

		int nextInt() throws RuntimeException {
			try {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return (int)st.nval;
		}

		void close() {
		}
	}

	@SuppressWarnings("unused")
	private static class Printer {
		PrintStream out;
		StringBuffer strbuf;
		int bufSize;
		final String CR;

		Printer(PrintStream out) {
			this.out = out;
			strbuf = new StringBuffer();
			bufSize = 64 * 1024;
			CR = System.getProperty("line.separator");
		}

		void println(String str) {
			strbuf.append(str);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(String str) {
			strbuf.append(str);
			checkStringBuffer();
		}

		void println(int n) {
			strbuf.append(n);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(int n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(long n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(char c) {
			strbuf.append(c);
			checkStringBuffer();
		}

		void printArray(int[] array) {
			for (int i = 0; i < array.length; i++) {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			}
			strbuf.delete(strbuf.length() - 1, strbuf.length());
			strbuf.append(CR);
		}

		void close() {
			flashStringBuffer();
		}

		private void flashStringBuffer() {
			if (strbuf.length() > 0) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}

		private void checkStringBuffer() {
			if (strbuf.length() > bufSize) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}
	}
} Main public static void main(String[] args) {
		Scanner sc = new Scanner(System.in); 
		Printer pr = new Printer(System.out); 

		int n = sc.nextInt();
		int m = sc.nextInt();
		int l = sc.nextInt();
		
		int[][] a = new int[n][m];
		int[][] b = new int[m][l];

		for (int i = 0; i < n; i++) {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		}
		for (int i = 0; i < m; i++) {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		}

//		int[][] c = new int[n][l];
		for (int i = 0; i < n; i++) {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		}

		pr.close();
		sc.close();
	} main {
		Scanner sc = new Scanner(System.in); 
		Printer pr = new Printer(System.out); 

		int n = sc.nextInt();
		int m = sc.nextInt();
		int l = sc.nextInt();
		
		int[][] a = new int[n][m];
		int[][] b = new int[m][l];

		for (int i = 0; i < n; i++) {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		}
		for (int i = 0; i < m; i++) {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		}

//		int[][] c = new int[n][l];
		for (int i = 0; i < n; i++) {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		}

		pr.close();
		sc.close();
	} Scanner sc = new Scanner(System.in); sc new Scanner(System.in) Printer pr = new Printer(System.out); pr new Printer(System.out) int n = sc.nextInt(); n sc.nextInt() sc.nextInt sc int m = sc.nextInt(); m sc.nextInt() sc.nextInt sc int l = sc.nextInt(); l sc.nextInt() sc.nextInt sc int[][] a = new int[n][m]; a new int[n][m] n m int[][] b = new int[m][l]; b new int[m][l] m l for (int i = 0; i < n; i++) {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		} {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		} for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			} int j = 0; int j = 0; j 0 j < m j m j++ j++ j {
				a[i][j] = sc.nextInt();
			} {
				a[i][j] = sc.nextInt();
			} a[i][j] = sc.nextInt() a[i][j] a[i] a i j sc.nextInt() sc.nextInt sc for (int i = 0; i < m; i++) {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		} int i = 0; int i = 0; i 0 i < m i m i++ i++ i {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		} {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		} for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			} int j = 0; int j = 0; j 0 j < l j l j++ j++ j {
				b[i][j] = sc.nextInt();
			} {
				b[i][j] = sc.nextInt();
			} b[i][j] = sc.nextInt() b[i][j] b[i] b i j sc.nextInt() sc.nextInt sc for (int i = 0; i < n; i++) {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		} int i = 0; int i = 0; i 0 i < n i n i++ i++ i {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		} {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		} for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			} int j = 0; int j = 0; j 0 j < l j l j++ j++ j {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			} {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			} long c = 0; c 0 for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				} int k = 0; int k = 0; k 0 k < m k m k++ k++ k {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				} {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				} c += a[i][k] * b[k][j] c a[i][k] * b[k][j] a[i][k] a[i] a i k b[k][j] b[k] b k j if (j != 0) {
					pr.print(" ");
				} j != 0 j 0 {
					pr.print(" ");
				} pr.print(" ") pr.print pr " " pr.print(c) pr.print pr c pr.println("") pr.println pr "" pr.close() pr.close pr sc.close() sc.close sc String[] args args private static class Scanner {
		InputStreamReader isr;
		BufferedReader br;
		StreamTokenizer st;

		private Scanner() {
		}

		Scanner (InputStream in) {
			isr = new InputStreamReader(in);
			br = new BufferedReader(isr);
			st = new StreamTokenizer(br);
		}

		String next() throws RuntimeException  {
			try {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return st.sval;
		}

		int nextInt() throws RuntimeException {
			try {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return (int)st.nval;
		}

		void close() {
		}
	} Scanner InputStreamReader isr; isr BufferedReader br; br StreamTokenizer st; st private Scanner() {
		} Scanner {
		} Scanner (InputStream in) {
			isr = new InputStreamReader(in);
			br = new BufferedReader(isr);
			st = new StreamTokenizer(br);
		} Scanner {
			isr = new InputStreamReader(in);
			br = new BufferedReader(isr);
			st = new StreamTokenizer(br);
		} isr = new InputStreamReader(in) isr new InputStreamReader(in) br = new BufferedReader(isr) br new BufferedReader(isr) st = new StreamTokenizer(br) st new StreamTokenizer(br) InputStream in in String next() throws RuntimeException  {
			try {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return st.sval;
		} next {
			try {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return st.sval;
		} try {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			} catch (IOException e) {
				throw new IllegalStateException();
			} IOException e {
				throw new IllegalStateException();
			} throw new IllegalStateException(); new IllegalStateException() {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} if (st.nextToken() != StreamTokenizer.TT_WORD) {
				} st.nextToken() != StreamTokenizer.TT_WORD st.nextToken() st.nextToken st StreamTokenizer.TT_WORD StreamTokenizer StreamTokenizer.TT_WORD {
				} return st.sval; st.sval st st.sval int nextInt() throws RuntimeException {
			try {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return (int)st.nval;
		} nextInt {
			try {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return (int)st.nval;
		} try {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			} catch (IOException e) {
				throw new IllegalStateException();
			} IOException e {
				throw new IllegalStateException();
			} throw new IllegalStateException(); new IllegalStateException() {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				} st.nextToken() != StreamTokenizer.TT_NUMBER st.nextToken() st.nextToken st StreamTokenizer.TT_NUMBER StreamTokenizer StreamTokenizer.TT_NUMBER {
					throw new InputMismatchException();
				} throw new InputMismatchException(); new InputMismatchException() return (int)st.nval; (int)st.nval st st.nval void close() {
		} close {
		} private static class Printer {
		PrintStream out;
		StringBuffer strbuf;
		int bufSize;
		final String CR;

		Printer(PrintStream out) {
			this.out = out;
			strbuf = new StringBuffer();
			bufSize = 64 * 1024;
			CR = System.getProperty("line.separator");
		}

		void println(String str) {
			strbuf.append(str);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(String str) {
			strbuf.append(str);
			checkStringBuffer();
		}

		void println(int n) {
			strbuf.append(n);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(int n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(long n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(char c) {
			strbuf.append(c);
			checkStringBuffer();
		}

		void printArray(int[] array) {
			for (int i = 0; i < array.length; i++) {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			}
			strbuf.delete(strbuf.length() - 1, strbuf.length());
			strbuf.append(CR);
		}

		void close() {
			flashStringBuffer();
		}

		private void flashStringBuffer() {
			if (strbuf.length() > 0) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}

		private void checkStringBuffer() {
			if (strbuf.length() > bufSize) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}
	} Printer PrintStream out; out StringBuffer strbuf; strbuf int bufSize; bufSize final String CR; CR Printer(PrintStream out) {
			this.out = out;
			strbuf = new StringBuffer();
			bufSize = 64 * 1024;
			CR = System.getProperty("line.separator");
		} Printer {
			this.out = out;
			strbuf = new StringBuffer();
			bufSize = 64 * 1024;
			CR = System.getProperty("line.separator");
		} this.out = out this.out this this.out out strbuf = new StringBuffer() strbuf new StringBuffer() bufSize = 64 * 1024 bufSize 64 * 1024 64 1024 CR = System.getProperty("line.separator") CR System.getProperty("line.separator") System.getProperty System "line.separator" PrintStream out out void println(String str) {
			strbuf.append(str);
			strbuf.append(CR);
			checkStringBuffer();
		} println {
			strbuf.append(str);
			strbuf.append(CR);
			checkStringBuffer();
		} strbuf.append(str) strbuf.append strbuf str strbuf.append(CR) strbuf.append strbuf CR checkStringBuffer() checkStringBuffer String str str void print(String str) {
			strbuf.append(str);
			checkStringBuffer();
		} print {
			strbuf.append(str);
			checkStringBuffer();
		} strbuf.append(str) strbuf.append strbuf str checkStringBuffer() checkStringBuffer String str str void println(int n) {
			strbuf.append(n);
			strbuf.append(CR);
			checkStringBuffer();
		} println {
			strbuf.append(n);
			strbuf.append(CR);
			checkStringBuffer();
		} strbuf.append(n) strbuf.append strbuf n strbuf.append(CR) strbuf.append strbuf CR checkStringBuffer() checkStringBuffer int n n void print(int n) {
			strbuf.append(n);
			checkStringBuffer();
		} print {
			strbuf.append(n);
			checkStringBuffer();
		} strbuf.append(n) strbuf.append strbuf n checkStringBuffer() checkStringBuffer int n n void print(long n) {
			strbuf.append(n);
			checkStringBuffer();
		} print {
			strbuf.append(n);
			checkStringBuffer();
		} strbuf.append(n) strbuf.append strbuf n checkStringBuffer() checkStringBuffer long n n void print(char c) {
			strbuf.append(c);
			checkStringBuffer();
		} print {
			strbuf.append(c);
			checkStringBuffer();
		} strbuf.append(c) strbuf.append strbuf c checkStringBuffer() checkStringBuffer char c c void printArray(int[] array) {
			for (int i = 0; i < array.length; i++) {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			}
			strbuf.delete(strbuf.length() - 1, strbuf.length());
			strbuf.append(CR);
		} printArray {
			for (int i = 0; i < array.length; i++) {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			}
			strbuf.delete(strbuf.length() - 1, strbuf.length());
			strbuf.append(CR);
		} for (int i = 0; i < array.length; i++) {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			} int i = 0; int i = 0; i 0 i < array.length i array.length array array.length i++ i++ i {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			} {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			} checkStringBuffer() checkStringBuffer strbuf.append(array[i]) strbuf.append strbuf array[i] array i strbuf.append(" ") strbuf.append strbuf " " strbuf.delete(strbuf.length() - 1, strbuf.length()) strbuf.delete strbuf strbuf.length() - 1 strbuf.length() strbuf.length strbuf 1 strbuf.length() strbuf.length strbuf strbuf.append(CR) strbuf.append strbuf CR int[] array array void close() {
			flashStringBuffer();
		} close {
			flashStringBuffer();
		} flashStringBuffer() flashStringBuffer private void flashStringBuffer() {
			if (strbuf.length() > 0) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		} flashStringBuffer {
			if (strbuf.length() > 0) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		} if (strbuf.length() > 0) {
				out.print(strbuf);
				strbuf.setLength(0);
			} strbuf.length() > 0 strbuf.length() strbuf.length strbuf 0 {
				out.print(strbuf);
				strbuf.setLength(0);
			} out.print(strbuf) out.print out strbuf strbuf.setLength(0) strbuf.setLength strbuf 0 private void checkStringBuffer() {
			if (strbuf.length() > bufSize) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		} checkStringBuffer {
			if (strbuf.length() > bufSize) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		} if (strbuf.length() > bufSize) {
				out.print(strbuf);
				strbuf.setLength(0);
			} strbuf.length() > bufSize strbuf.length() strbuf.length strbuf bufSize {
				out.print(strbuf);
				strbuf.setLength(0);
			} out.print(strbuf) out.print out strbuf strbuf.setLength(0) strbuf.setLength strbuf 0 public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in); 
		Printer pr = new Printer(System.out); 

		int n = sc.nextInt();
		int m = sc.nextInt();
		int l = sc.nextInt();
		
		int[][] a = new int[n][m];
		int[][] b = new int[m][l];

		for (int i = 0; i < n; i++) {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		}
		for (int i = 0; i < m; i++) {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		}

//		int[][] c = new int[n][l];
		for (int i = 0; i < n; i++) {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		}

		pr.close();
		sc.close();
	}

	@SuppressWarnings("unused")
	private static class Scanner {
		InputStreamReader isr;
		BufferedReader br;
		StreamTokenizer st;

		private Scanner() {
		}

		Scanner (InputStream in) {
			isr = new InputStreamReader(in);
			br = new BufferedReader(isr);
			st = new StreamTokenizer(br);
		}

		String next() throws RuntimeException  {
			try {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return st.sval;
		}

		int nextInt() throws RuntimeException {
			try {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return (int)st.nval;
		}

		void close() {
		}
	}

	@SuppressWarnings("unused")
	private static class Printer {
		PrintStream out;
		StringBuffer strbuf;
		int bufSize;
		final String CR;

		Printer(PrintStream out) {
			this.out = out;
			strbuf = new StringBuffer();
			bufSize = 64 * 1024;
			CR = System.getProperty("line.separator");
		}

		void println(String str) {
			strbuf.append(str);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(String str) {
			strbuf.append(str);
			checkStringBuffer();
		}

		void println(int n) {
			strbuf.append(n);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(int n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(long n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(char c) {
			strbuf.append(c);
			checkStringBuffer();
		}

		void printArray(int[] array) {
			for (int i = 0; i < array.length; i++) {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			}
			strbuf.delete(strbuf.length() - 1, strbuf.length());
			strbuf.append(CR);
		}

		void close() {
			flashStringBuffer();
		}

		private void flashStringBuffer() {
			if (strbuf.length() > 0) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}

		private void checkStringBuffer() {
			if (strbuf.length() > bufSize) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}
	}
} public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in); 
		Printer pr = new Printer(System.out); 

		int n = sc.nextInt();
		int m = sc.nextInt();
		int l = sc.nextInt();
		
		int[][] a = new int[n][m];
		int[][] b = new int[m][l];

		for (int i = 0; i < n; i++) {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		}
		for (int i = 0; i < m; i++) {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		}

//		int[][] c = new int[n][l];
		for (int i = 0; i < n; i++) {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		}

		pr.close();
		sc.close();
	}

	@SuppressWarnings("unused")
	private static class Scanner {
		InputStreamReader isr;
		BufferedReader br;
		StreamTokenizer st;

		private Scanner() {
		}

		Scanner (InputStream in) {
			isr = new InputStreamReader(in);
			br = new BufferedReader(isr);
			st = new StreamTokenizer(br);
		}

		String next() throws RuntimeException  {
			try {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return st.sval;
		}

		int nextInt() throws RuntimeException {
			try {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return (int)st.nval;
		}

		void close() {
		}
	}

	@SuppressWarnings("unused")
	private static class Printer {
		PrintStream out;
		StringBuffer strbuf;
		int bufSize;
		final String CR;

		Printer(PrintStream out) {
			this.out = out;
			strbuf = new StringBuffer();
			bufSize = 64 * 1024;
			CR = System.getProperty("line.separator");
		}

		void println(String str) {
			strbuf.append(str);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(String str) {
			strbuf.append(str);
			checkStringBuffer();
		}

		void println(int n) {
			strbuf.append(n);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(int n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(long n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(char c) {
			strbuf.append(c);
			checkStringBuffer();
		}

		void printArray(int[] array) {
			for (int i = 0; i < array.length; i++) {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			}
			strbuf.delete(strbuf.length() - 1, strbuf.length());
			strbuf.append(CR);
		}

		void close() {
			flashStringBuffer();
		}

		private void flashStringBuffer() {
			if (strbuf.length() > 0) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}

		private void checkStringBuffer() {
			if (strbuf.length() > bufSize) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}
	}
} Main
import java.io.BufferedReader;
import java.io.IOException;
import java.io.InputStream;
import java.io.InputStreamReader;
import java.io.PrintStream;
import java.io.StreamTokenizer;
import java.util.InputMismatchException;


public class Main {

	public static void main(String[] args) {
		Scanner sc = new Scanner(System.in); 
		Printer pr = new Printer(System.out); 

		int n = sc.nextInt();
		int m = sc.nextInt();
		int l = sc.nextInt();
		
		int[][] a = new int[n][m];
		int[][] b = new int[m][l];

		for (int i = 0; i < n; i++) {
			for (int j = 0; j < m; j++) {
				a[i][j] = sc.nextInt();
			}
		}
		for (int i = 0; i < m; i++) {
			for (int j = 0; j < l; j++) {
				b[i][j] = sc.nextInt();
			}
		}

//		int[][] c = new int[n][l];
		for (int i = 0; i < n; i++) {
			for (int j = 0; j < l; j++) {
				long c = 0;
				for (int k = 0; k < m; k++) {
//					c[i][j] += a[i][k] * b[k][j];
					c += a[i][k] * b[k][j];
				}
				if (j != 0) {
					pr.print(" ");
				}
				pr.print(c);
			}
			pr.println("");
		}

		pr.close();
		sc.close();
	}

	@SuppressWarnings("unused")
	private static class Scanner {
		InputStreamReader isr;
		BufferedReader br;
		StreamTokenizer st;

		private Scanner() {
		}

		Scanner (InputStream in) {
			isr = new InputStreamReader(in);
			br = new BufferedReader(isr);
			st = new StreamTokenizer(br);
		}

		String next() throws RuntimeException  {
			try {
				if (st.nextToken() != StreamTokenizer.TT_WORD) {
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return st.sval;
		}

		int nextInt() throws RuntimeException {
			try {
				if (st.nextToken() != StreamTokenizer.TT_NUMBER) {
					throw new InputMismatchException();
				}
			} catch (IOException e) {
				throw new IllegalStateException();
			}

			return (int)st.nval;
		}

		void close() {
		}
	}

	@SuppressWarnings("unused")
	private static class Printer {
		PrintStream out;
		StringBuffer strbuf;
		int bufSize;
		final String CR;

		Printer(PrintStream out) {
			this.out = out;
			strbuf = new StringBuffer();
			bufSize = 64 * 1024;
			CR = System.getProperty("line.separator");
		}

		void println(String str) {
			strbuf.append(str);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(String str) {
			strbuf.append(str);
			checkStringBuffer();
		}

		void println(int n) {
			strbuf.append(n);
			strbuf.append(CR);
			checkStringBuffer();
		}

		void print(int n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(long n) {
			strbuf.append(n);
			checkStringBuffer();
		}

		void print(char c) {
			strbuf.append(c);
			checkStringBuffer();
		}

		void printArray(int[] array) {
			for (int i = 0; i < array.length; i++) {
				checkStringBuffer();
				strbuf.append(array[i]);
				strbuf.append(" ");
			}
			strbuf.delete(strbuf.length() - 1, strbuf.length());
			strbuf.append(CR);
		}

		void close() {
			flashStringBuffer();
		}

		private void flashStringBuffer() {
			if (strbuf.length() > 0) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}

		private void checkStringBuffer() {
			if (strbuf.length() > bufSize) {
				out.print(strbuf);
				strbuf.setLength(0);
			}
		}
	}
}