What I was thinking would be to have a look ahead for a number.
my $string = '1 Cat 2 Dogs 3 Hamsters'; my @animals = split /(?=\d)/, $string;
-Bryan
In reply to Re: problems splitting string
by mrborisguy
in thread problems splitting string
by Anonymous Monk
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |