Python: Parsing
Revision as of 10:57, 30 November 2015 by Onnowpurbo (talk | contribs) (New page: "hello world sample text".split() will split on any whitespace. If you only want to split on spaces "hello world sample text".split(" ") regex version would be something like this ...)
"hello world sample text".split()
will split on any whitespace. If you only want to split on spaces
"hello world sample text".split(" ")
regex version would be something like this
re.split(" +", "hello world sample text")
which works if you have multiple spaces between the words