Beefy Boxes and Bandwidth Generously Provided by pair Networks
"be consistent"
 
PerlMonks  

Re: Add an arrayref to a hashref

by haukex (Bishop)
on Aug 12, 2019 at 19:23 UTC ( #11104347=note: print w/replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    $hashref->{personal} = $arrayref;
    # Results in:
    ...
      designation => "Manager",
      personal    => ["Country", "location", "language"],
    }
    
  2. or download this
    @{$hashref}{@$arrayref} = ();
    # Results in:
    ...
      location    => undef,
      language    => undef,
    }
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://11104347]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others romping around the Monastery: (7)
As of 2020-11-26 10:38 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found

    Notices?