my @kept = grep { ! m/CONDITION_FOR_DELETION/ } @array;