in reply to Re: multiple matches with regexp
in thread multiple matches with regexp
The main difference is, that I match the pattern at the beginning of the string while you match it on the substr$regexp="a{2}"; $_="aaaa"; do { push @a, $1 if ( m/^($regexp)/ ) } while ( s/^.// ) ; print join ( "-", @a );
Thanks for the input.
|
|---|