in reply to Perl:how to find multiple strings
In addition to what wind had to suggest
you'll want to do something to prevent /1=\Q$TAB_1\E/ from matching 21=, and so on. Probably something as simple as putting a blank in front of the 1= and 5=, in your context.my $matches = grep {/1=\Q$TAB_1\E/ && /5=\Q$TAB_5\E/} @contents ;
|
|---|