why don't you use grep ?
@res = grep { $_ =~ // } @array
$toto = "@res";
or
$toto="";
foreach (@array) {
$toto .= $_;
}
--- Evan Morris <evan@xxxxxxxxxxxxxxxxxx> a écrit : >
Hi
>
> Can you use a 'for each' statement in conjunction
> with a regex to get out
> every match of the regex in a string?
>
> Thanks
>
> _______________________________________________
> ActivePerl mailing list
> ActivePerl@xxxxxxxxxxxxxxxxxxxxxxxx
> To unsubscribe:
http://listserv.ActiveState.com/mailman/mysubs
___________________________________________________________
Do You Yahoo!? -- Une adresse @yahoo.fr gratuite et en français !
Yahoo! Mail : http://fr.mail.yahoo.com
_______________________________________________
ActivePerl mailing list
ActivePerl@xxxxxxxxxxxxxxxxxxxxxxxx
To unsubscribe: http://listserv.ActiveState.com/mailman/mysubs
|