import re
string = "哈哈哈sfasfafasf哈哈哈"
#replace(oldStr,newStr)
newString = string.replace("哈哈哈"," ")
#正则替换非字母的字符
re.sub(r"([^a-z])"," ",string)
- THE END -
最后修改:2020年10月22日