for my $key ( keys %$data ) { print "key: $key\n"; ...