str = "11100011" #'1' 과 '0'을 각각 'a' , 'b'로 변경 str = str.translate(str.maketrans('10', 'ab')) print(str)
aaabbbaa