use warnings; use strict; use Tie::File; tie (my @file1, 'Tie::File', $filename1) or die $!; tie (my @file2, 'Tie::File', $filename2) or die $!; # sortieren @file1 = sort(@file1); @file2 = sort(@file2);