n = 5 m = 3 readMatr :: IO [[Int]] readMatr = sequence . replicate n $ fmap (map read . take m . words) getLine main = readMatr >>= print