I'm practicing loops. I've been trying to figure out how to get each character printed 4 times and place aside the others, eg: aaaaccccddddcccc. Right now the returned res is only showing me the last character printed 4 times (cccc). I tried nested for loops but that wasn't working for me either. How do I concatenate the returns? (or is there another way)
def quad_char(letter):
res = ''
for i in letter:
res = i * 4
return res
print(quad_char('acdc'))