Run
import re string1 = '''Welcome to pythonexamples.org''' #split string by single new-line chunks = re.split('\n', string1) print(chunks)
Output