in reply to Sorting HoHoA based on Length of Second Key

Here is what I managed to get working:

print foreach (sort {(length ((keys %{$HoHoA{$b}})[0])) <=> length((keys %{$HoHoA{$a}})[0]) } keys %HoHoA);

It only works if all second keys are the same length (which is the case with your submitted code)
Is that what you want?

P!