Result

AC

Duration

1012ms

Code [DL]

$><<gets.gsub(/.\d/){$&[0]*$&[1].to_i}

stdin

m6y3u9l5o6jeag3p8p3z4a4z4w9f8o8ar8y3n6h2g4m2l9y6x7p9q2n6k9cn9o3t4w5p7j3t5i6r7s8a9n9h4d9k3bv4p7

stdout

mmmmmmyyyuuuuuuuuullllloooooojeagggpppppppppppzzzzaaaazzzzwwwwwwwwwffffffffooooooooarrrrrrrryyynnnnnnhhggggmmlllllllllyyyyyyxxxxxxxpppppppppqqnnnnnnkkkkkkkkkcnnnnnnnnnooottttwwwwwpppppppjjjtttttiiiiiirrrrrrrssssssssaaaaaaaaannnnnnnnnhhhhdddddddddkkkbvvvvppppppp

stderr

strace