in reply to Array length within a hash

Try

foreach my $key (keys %Hash) { push @hasharraylengths, scalar @{$Hash{$key}}; }

The idea : $Hash{$key} is an array reference. Dereference, with @{}, and force scalar ccntext with scalar.

HTH