-- yukicoder My Practice -- author: Leonardone @ NEETSDKASU main = interact $ unlines . map (foldl1 (++) . map show) . reverse . foldl1 ((. head) . map . flip replicate . head . head) . map return . zipWith ($) [return, flip take [1..]] . repeat . read