http://www.perlmonks.org?node_id=140068


in reply to each() function used in associative arrays gives incorrect unordered output.

If you want ordered output you could use
foreach my $key (sort(keys %array)) { print "$key = $array{$key}\n"; }
  • Comment on Re: each() function used in associative arrays gives incorrect unordered output.
  • Download Code