
Dec. 13, 2008
8:30 p.m.
Bruce Leban wrote:
[i for i in s.split(x) if i] is simple enough if I don't know how to write "(" + re.escape(x) + ")+".
The point of the dropempty keyword would be less the dropempty=True case as the s.split(None, dropempty=False) case, which would otherwise require a regexp. -- Carl