Python字符串方法总结

s="      12345"

方法名(函数名) 作用(描述) 举例

strip()函数

去除字符串头尾指定的字符,默认为空格或换行符 s.strip()==>"12345"
   
     
     
     
     
     

猜你喜欢

转载自blog.csdn.net/weixin_44961794/article/details/103102482