in reply to Re^2: removing duplicate lines
in thread removing duplicate lines

I used the hash slice method to find unique names because it seems to be the most efficient method following benchmarking, see Re^3: What does 'next if $hash{$elem}++;' mean?. I felt that the overhead of re-sorting the keys of the %uniques hash would not outweigh the efficiencies of the hash slice method but I admit I have not benchmarked this.

As to our versus my, I tend to reserve my for subroutines or scoped code blocks and use our in the main part of the script but I realise that in this case it would make little difference.

Cheers,

JohnGG