in reply to how to sort

Sort the indices, not the arrays themselves:

my @indices= 0..$#arr_score; @indices= sort { $arr_score[ $a ] <=> $arr_score[ $b ] } @indices; for my $i (@indices) { print "$arr_thumbnail[ $i ] - $arr_url[ $i ] - $arr_score[ $i ]\n" +; };

Alternatively, restructure your data into hashes, and sort that array.