import Control.Monad
main = do
  mnl_in <- (return . map (read::String->Int) . words) =<< getLine
  let m:n:l:[] = mnl_in
  mA <- replicateM m $ (return . map (read::String->Int) . words) =<< getLine
  mB <- replicateM n $ (return . map (read::String->Int) . words) =<< getLine
  let mAB = matmul mA mB
  forM_ [0..m-1] $ \i -> do
    forM_ [0..l-1] $ \j -> do
      putStr $ show ((mAB!!i)!!j)
      putStr $ if j == l-1 then "\n" else " "
      
matmul :: [[Int]] -> [[Int]] -> [[Int]]
matmul mA mB = let r = length mA
                   c = length $ mB!!0
                   mAi i = mA !! i
                   mBj j = [(mB!!i)!!j |i<-[0..((length $ mB) -1)]]
                  in [[sum . map (\(x,y)->x*y) $ zip (mAi i) (mBj j)| j<-[0..c-1]] |i<-[0..r-1]]
