- or download this
my @arr = qw/ foo foozle bar bar2 foo bar foo /;
...
print "$_\n" for (@arr);
## output: bar2 is NOT removed
- or download this
@chroms = grep { ! /[pqxy]/i } @chroms;
- or download this
for (my $i=0; $i<@chroms; $i++) {
splice(@chroms, $i--, 1) if not $chroms[$i] =~ /[pqxy]/i;
} ####