in reply to Re: How to make sure no elements from @array are inside $scalar
in thread How to make sure no elements from @array are inside $scalar
Output:use List::Util qw( none ); my $text = 'f000124_9019_90181234_dp'; my $sites = [ '018', '324' ]; if ($text =~ /_9(...)/, none {$1 eq $_} @$sites) { print "$1 doesn't match anything: to be removed..\n" }
This isn't how your original code worked.019 doesn't match anything: to be removed..
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^3: How to make sure no elements from @array are inside $scalar
by Steffen (Novice) on Nov 14, 2014 at 17:18 UTC |