Perl library to compare arrays