in reply to Re: regex match in array
in thread regex match in array
will match, but i would only like it to match if the _term_ is /^blah foo(.*)/#!/usr/bin/perl use strict; use warnings; my @myTerms = ( 'blah foo', 'test' ); my $term = "blah"; if ( grep /\Q$term\E/, @myTerms) { print "$term does match\n"; } # end-if exit;
|
|---|