Thanks,my $suffix = ".zip"; # value is likely to change foreach my $file (@dir_list) { if ($file =~ /$suffix$/e) { print "Match on $file!\n"; do_this(); do_that(); } }
In reply to Best way to match items in an array by ibanix
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |