in reply to printing hash of array

You were very close.

Here's the final piece that you needed, which was to dereference the hash info using the value of the key $code:

use strict; use warnings; + my $info = { 'last' => [ 'jones', 'smith', 'long' ] }; + + foreach my $code ( keys %{$info} ) { print $code . ":"; foreach my $last ( @{$info->{$code}} ) { print " " . $last; } print "\n"; }

s''(q.S:$/9=(T1';s;(..)(..);$..=substr+crypt($1,$2),2,3;eg;print$..$/