How to split a list-of-strings into sublists-of-strings by a specific string element – stackoverflow.com

I have a word list like below. I want to split the list by .. Is there any better or useful code in Python 3? a = ['this', 'is', 'a', 'cat', '.', 'hello', '.', 'she', 'is', 'nice', '.'] result = [] ...

from Hot Questions - Stack Exchange OnStackOverflow
via Blogspot

Share this

0 Comment to "How to split a list-of-strings into sublists-of-strings by a specific string element – stackoverflow.com"