in reply to How could I simplify this redundant-column-removing code?

A couple suggestions:
  1. If you are just incrementing by 1, use Foreach Loops instead of C-style loops -- fewer moving parts:
    for my $i (0 .. @F-1) {
  2. Avoid punctuation variables if you can, unless this is your toy and you are super comfy with them. Rather than testing $., just test if @F1 is initialized:
    @F1 = @F if !@F1;
    Note that you shouldn't use logical compound assignment operators because they have scalar context.
  3. Contrasting the above, you should be using $_ in this case because $line is so highly localized.
    while (<DATA>) { chomp; my @F = split '&';
  4. +@F1 is a no-op. Numification requires two arguments, so you'd need to write 0+@F1, but you don't even need to do that because logical operators like != also apply scalar context to their arguments.
  5. Your algorithm gets simpler and allows using a hash if you track which terms to delete rather than which ones to keep. I'm assuming that you don't have repeated keys.
So I might write that as:
#!/usr/bin/env perl -w use v5.014; my %seen; my $count; my @recs; while (<DATA>) { chomp; my @F = split '&'; $count //= @F; die "NF mismatch" if @F != $count; $seen{$_}++ for @F; push @recs, \@F; } for my $rec (@recs) { say join "\t", grep $seen{$_} != @recs, # Doesn't show up in every record @$rec ; } __DATA__ a=1&b=1&c=1&d=2&e=&f=3 a=1&b=2&c=3&d=2&e=&f=4 a=1&b=2&c=5&d=1&e=&f=5

#11929 First ask yourself `How would I do this without a computer?' Then have the computer do it the same way.