python 去掉字符串中的空格以及换行符 replace() 的用法

str.replace(old, new[, max])
old -- 将被替换的子字符串。
new -- 新字符串,用于替换old子字符串。
max -- 可选字符串, 替换不超过 max 次
发布了16 篇原创文章 · 获赞 3 · 访问量 6673

猜你喜欢

转载自blog.csdn.net/chilitian/article/details/84574192
今日推荐