push @a, "aaa"; push @a, "bbb"; if ( @a =~ m/aa/) { #how do I print the line in @a that matches 'aa' #without going through the array. } [download]
In reply to smart match capture by perlperlperl