in reply to How do I split a string which has letters then numbers?
Change the regexes if your data needs more complex parsing.my ($word, $number) = split /(?<=\D)(?=\d)/; my ($word, $number) = /^(\D+)(\d+)$/;
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: How do I split a string which has letters then numbers?
by japhy (Canon) on Jan 17, 2002 at 04:43 UTC |