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


in reply to Building a hash from file and getting wrong result.

I'd guess keys is missing here:
foreach my $recid ( reverse sort keys %SeqOrders ) # ~~~~

So, you're mixing keys and values together and sorting them.

($q=q:Sq=~/;[c](.)(.)/;chr(-||-|5+lengthSq)`"S|oS2"`map{chr |+ord }map{substrSq`S_+|`|}3E|-|`7**2-3:)=~y+S|`+$1,++print+eval$q,q,a,