reference로 넘기면 된답니다.
#!/usr/bin/perl
sub printKey {
my ($myhash,$key) = @_;
print "Key=$key, Value=$myhash->{$key}\n";
}
%testHash = (
a => "AKey",
b => "BKey",
c => "CKey"
);
printKey( \%testHash, "a");
printKey( \%testHash, "c");
printKey( \%testHash, "x");