in reply to Re: problems splitting string
in thread problems splitting string

That kinda works: it leaves a trailing space on the middle elements (i.e., '1 Cat ' instead of '1 Cat').

Of course, that may be immaterial to the OP -- can't tell.

Replies are listed 'Best First'.
Re^3: problems splitting string
by mrborisguy (Hermit) on Dec 15, 2005 at 16:11 UTC

    Yep. Good catch, I noticed that, and was changing it, then I noticed you posted. I tried to update with a solution using map to take off the trailing space, but it seems VSarkiss' solution is similar to mine but more elegant, so just refer down a few posts.

        -Bryan