cnv [] = []
cnv x@(xh:xs) =
  let l = length $ takeWhile (== xh) x
      r = drop l x
  in
    (show l)++[xh]++(cnv r)

ans 0 s = s
ans n s = ans (n-1) $ cnv s

main = do
  n <- getLine
  s <- getLine
  let n' = read n :: Int
      o  = ans n' s
  putStrLn o