PERL: Merge Sort