Beefy Boxes and Bandwidth Generously Provided by pair Networks
Keep It Simple, Stupid

Re^4: Localizing hash keys in an AoH

by NetWallah (Abbot)
on Mar 16, 2013 at 03:11 UTC ( #1023804=note: print w/ replies, xml ) Need Help??

in reply to Re^3: Localizing hash keys in an AoH
in thread Localizing hash keys in an AoH

Looks like you can do all that in a single line as well:

perl -E 'use strict;my @x=map {Z=>$_+999}, 0..5;{$_->{Z}=33 for local + @x[0..$#x]; say $x[2]{Z}}; say $x[2]{Z}' 33 1001

             "I'm fairly sure if they took porn off the Internet, there'd only be one website left, and it'd be called 'Bring Back the Porn!'"
        -- Dr. Cox, Scrubs

Comment on Re^4: Localizing hash keys in an AoH
Download Code

Log In?

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

How do I use this? | Other CB clients
Other Users?
Others browsing the Monastery: (2)
As of 2015-11-28 11:38 GMT
Find Nodes?
    Voting Booth?

    What would be the most significant thing to happen if a rope (or wire) tied the Earth and the Moon together?

    Results (741 votes), past polls