Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Hash element access -dereferenced hashes

by choroba (Chancellor)
on Dec 06, 2012 at 10:10 UTC ( #1007507=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    %hash1 = (key1   => "value1");
    %hash2 = (value1 => "Gotcha");
    print $hash2{ $hash1{key1} }, "\n"; # Not $key1!
    
  2. or download this
    Gotcha
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1007507]
help
Chatterbox?
[SuicideJunkie]: Parse a serial number from a register. But it is humans that type it in originally.
[SuicideJunkie]: No respect for buffer sizes... give them a byte, they take three :D

How do I use this? | Other CB clients
Other Users?
Others about the Monastery: (14)
As of 2016-12-07 22:16 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    On a regular basis, I'm most likely to spy upon:













    Results (131 votes). Check out past polls.