push @array, map { $_->[1] =~ s/[\s?,]//g; $_->[1]; } grep { $_->[0] =~ /\S/ } @rows;