Generally, I use Text::ParseWords. But that's because I like the option for the user to pass in word "some phrase" word to get only three "words" out of it, basically allowing a form of escaping on spaces that makes sense. This isn't a whole lot more complicated than using split ' ', $string, but offers huge amounts of extra flexibility. Whether you do this or not is dependant on whether you want that flexibility or not.
In reply to Re: the best way to separate a string into words
by Tanktalus
in thread the best way to separate a string into words
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |