http://qs321.pair.com?node_id=469195


in reply to One line assigment statement with regex match

Do you mean something like:
my @terms = qw(one two three); @matches = grep { my $line = $_; grep {$line =~ /$_/} @terms } @lines_ +from_file;
?

Ivan Heffner
Sr. Software Engineer, DAS Lead
WhitePages.com, Inc.