fork download
  1. import Data.List
  2.  
  3. yoba n = foldr ((\g -> g . transpose . g) . map . (:)) [[0]] [1..n]
  4.  
  5. main = mapM_ (putStrLn . concat . intersperse "\t" . map show) $ yoba 9
Success #stdin #stdout 0s 6228KB
stdin
Standard input is empty
stdout
1	1	1	1	1	1	1	1	1	1
1	2	2	2	2	2	2	2	2	2
1	2	3	3	3	3	3	3	3	3
1	2	3	4	4	4	4	4	4	4
1	2	3	4	5	5	5	5	5	5
1	2	3	4	5	6	6	6	6	6
1	2	3	4	5	6	7	7	7	7
1	2	3	4	5	6	7	8	8	8
1	2	3	4	5	6	7	8	9	9
1	2	3	4	5	6	7	8	9	0