Thanks again for your SPEEDY reply.
Your illustrations below helped me a lot. I'm beginning to get an idea
of the power of perl & regexps in perl. I'm starting to be majorly
impressed with it all.
I think I grasp what I need to be doing now. Again thanks for all your
help & your time.
On 11 Sep 2001 13:12:42 +0200, HOLLAND-MORITZ,MARCUS (A-hsgGermany,ex1)
wrote:
>
> Say you have:
>
> $string = 'some numbers: 42, 4711, 314';
>
> Then you could extract all numbers using the /g modifier for regexes:
>
> @numbers = $string =~ /(\d+)/g;
>
> The array @numbers automatically provides list context for the match,
> the parentheses catch one or more (+) digits (\d), and the /g modifier
> makes the regex grab all matches.
>
> print "@numbers\n";
>
> will print:
>
> 42 4711 314
>
> | --
> | regs
> | rupert
> |
>
> -- Marcus
--
regs
rupert
--
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]