|
|
| Welcome to the Monastery | |
| PerlMonks |
Re: how to split the string into two or three numbers based on certain value.by moritz (Cardinal) |
| on Feb 11, 2013 at 20:51 UTC ( #1018239=note: print w/ replies, xml ) | Need Help?? |
|
If you really want a regex-solution (which isn't necessarily the best idea), here's one from the bottom of the poison cabinet:
I'm sure that can be simplified somehow, but right now I don't know how. Be sure to read the warning about (??{...}) in perlre. And here's a nicer Perl 6 solution:
In Section
Seekers of Perl Wisdom
|
|
||||||||||||||||||||||||||