http://qs321.pair.com?node_id=651911

Anonymous Monk has asked for the wisdom of the Perl Monks concerning the following question:

Hello all, I have a school assignment but I seem to be unable to begin... What I was given is something like the following
my @out= (b,a,c,d,a,b,f,g,a,c,g); my @out1=(1,2,3,1,2,3,4,5,2,3,2);#the numbers declares how many times +the letters from the @out are found
I want to make a hash contains as keys the unique elements from the @out and as values the sums of the letters from the @out1. Also I want the hash to be sorted
This is the preview of the hash %hash=(a=>6,b=>4,c=>6,d=>1,f=>4,g=>7)
any ideas please?