Akhthar Parvez K wrote:
Jim,
Why do you call us Jim?
[...] how would you tell Perl to pick 'cd' of 'abcd' and 'abcd' itself and 'pq' of 'pqrs' and 'pqrs' itself, and nothing else, from an array ( = 'abcdpqrsxyz') by a single statement.
Why an array? Don't you mean a string? my $s = 'abcdpqrsxyz'; my @match = $s =~ /ab(cd)(pq)rs/; -- Ruud -- To unsubscribe, e-mail: beginners-unsubscr...@perl.org For additional commands, e-mail: beginners-h...@perl.org http://learn.perl.org/