go ahead... be a heretic | |
PerlMonks |
Re: Split using multiple conditionsby bart (Canon) |
on Jun 11, 2005 at 11:31 UTC ( [id://465792]=note: print w/replies, xml ) | Need Help?? |
That's an official FAQ: perlfaq 4: How can I split a [character] delimited string except when inside [character]?
Personally, I'd be inclined to use the dual approach: match the stuff between brackets, or nonspaces.
Yes it can be that compact. Result:
A limitation is that you can't easily split on single spaces, thus returning empty strings as a section.
In Section
Seekers of Perl Wisdom
|
|