python输入一句话,将所有的字母r去掉python输入一句话,将所有的字母r去掉python输入一句话,将所有的字母r去掉
str = input() print(str.replace("r", ""))
f = "hello world rrrRRR" # 含有字母r的字符 new_f = f.replace("r", "") # 将字符中的字母r 去掉 print(new_f) # 打印结果 >>> hello wold
不知博主想要的是不是这种