sub by_score { $totalscoreinv{$keyscore}{$b}<=>$totalscoreinv{$keyscore}{$a}; }