python-去除去除字符串首尾的字符strip()

# for title in titles: # print title.strip() #Python strip() 方法用於移除字符串頭尾指定的字符(默認爲空格)。 strip()方法語法:python str.strip([chars]); chars -- 移除字符串頭尾指定的字符。 返回移除字符串頭尾指定的字符生成的新字符串。 str = "0000000 Runo
相關文章
相關標籤/搜索