Beefy Boxes and Bandwidth Generously Provided by pair Networks
Welcome to the Monastery
 
PerlMonks  

Re^4: Variable as name of array

by choroba (Canon)
on Nov 01, 2012 at 22:56 UTC ( #1001882=note: print w/ replies, xml ) Need Help??


in reply to Re^3: Variable as name of array
in thread Variable as name of array

Or even, horrors, a slice:

use Data::Dumper; my @names = qw/ A B C D /; my %order; @order{ @names } = @names; print Dumper \%order; __END__ Prints: $VAR1 = { 'A' => 'A', 'D' => 'D', 'C' => 'C', 'B' => 'B' };
لսႽ ᥲᥒ⚪⟊Ⴙᘓᖇ Ꮅᘓᖇ⎱ Ⴙᥲ𝇋ƙᘓᖇ


Comment on Re^4: Variable as name of array
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (7)
As of 2015-07-03 08:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (49 votes), past polls