in reply to Using an element in a Hash of Arrays to access the key

 print $hash{fruit}{banana}

update

Oops sorry too fast, it's

print $hash{fruit}[0]

Since you constructed a hash of arrays

Cheers Rolf
(addicted to the Perl Programming Language and ☆☆☆☆ :)
Je suis Charlie!

Replies are listed 'Best First'.
Re^2: Using an element in a Hash of Arrays to access the key
by orangepeel1 (Novice) on Mar 25, 2017 at 17:21 UTC
    Wouldn't this assume that I know that banana belongs to fruit already?
      Sorry seems like I misread your question.

      And haukex already gave you an exhaustive reply.

      Cheers Rolf
      (addicted to the Perl Programming Language and ☆☆☆☆ :)
      Je suis Charlie!