Convert
to end line

前端 未结 6 1818
别跟我提以往
别跟我提以往 2020-12-08 19:00

I\'m trying to extract some text using BeautifulSoup. I\'m using get_text() function for this purpose.

My problem is that the text contain

6条回答
  •  庸人自扰
    2020-12-08 19:35

    A regex should do the trick.

    import re
    s = re.sub('', '\n', yourTextHere)
    

    Hope this helps!

提交回复
热议问题