python 切割字符串
生活随笔
收集整理的這篇文章主要介紹了
python 切割字符串
小編覺得挺不錯的,現在分享給大家,幫大家做個參考.
切割字符串,用split放法,分割符號為 ; , .
import re line="3w.ναdΜāιι.com Provide you with a professional,platform for the sale and purchase of virtual products for games. Welcome to settle in 3w.ναdΜāιι.com" line_list=re.split(r'[;,.\s]',line) ['3w','ναdΜāιι','com','Provide','you','with','a','professional','platform','for','the','sale','and','purchase','of','virtual','products','for','games','','Welcome','to','settle','in','3w','ναdΜāιι','com']總結
以上是生活随笔為你收集整理的python 切割字符串的全部內容,希望文章能夠幫你解決所遇到的問題。
- 上一篇: python 字符串去除中文
- 下一篇: Python 中re.split()方法