Codewars notes- 双字符 字符串
def double_char(s): s2 = '' for i in s: i += i s2 += i return s2
*replace()函数
*tanslate()-str.maketrans(oldstr, newstr, delstr)
def double_char(s): s2 = '' for i in s: i += i s2 += i return s2
*replace()函数
*tanslate()-str.maketrans(oldstr, newstr, delstr)