Repeat the characters [FINALIZED]
+5
−0
Given a string and a non-negative integer $n$, output a new string in which each character is repeated $n$ times.
Test cases:
"abc", 1 -> "abc"
"Hello", 0 -> ""
"double", 2 -> "ddoouubbllee"
"Hi", 4 -> "HHHHiiii"
"", 20 -> ""
0 comment threads