in reply to sort an array according to another array
i take it than when you traverse the larger array that you're looping through the index number. use that number as the key when you're creating the small hash. then a simple sort keys %small_hash gives them to you in order.