in reply to How can I print hash values when the keys are the values from another hash.

How about this?:

my %hashA = ( this => 'A', that => 'B', other => 'C' ); my %hashB = ( A => 'aye', B => 'bee', C => 'see' ); { local $" = "\n"; print "@hashB{ values( %hashA ) }\n"; }

Dave

  • Comment on Re: How can I print hash values when the keys are the values from another hash.
  • Download Code