note
igelkott
<blockquote><i><c>/$pat/g</c></i></blockquote>
<p>Perhaps I've misunderstood but with my current <c>$var</c>, using <c>/$pat/g</c> will result in no matches (with or without the 'g' modifier). As far as I know, this will look for the literal string of '$_ < 3' on my array, as written below (appending to the initial script).</p>
<c>@res = grep {/$pat/g} @arr;
print "Search:\t@res\n";
</c>
<p>This finds none of the elements of <c>@arr</c>.</p>
1094064
1094090