my @sum; while () { chomp; my @F = split /\t/; $sum[$_] += $F[$_] for 0..@F-1; }