There's more than one way to do things | |
PerlMonks |
Re^2: How to write a regular expression to extract a number from an embedded string?by pbeckingham (Parson) |
on Jul 28, 2004 at 16:54 UTC ( [id://378112]=note: print w/replies, xml ) | Need Help?? |
Please be aware that your suggestion of using will greedily include everything to the end of the string. The OP specifically states 8 digits, with possible whitespace breaking the digits into groups of 4. While your suggestion works on your test data, it will not work on certain other data.
In Section
Seekers of Perl Wisdom
|
|