Beefy Boxes and Bandwidth Generously Provided by pair Networks
Perl: the Markov chain saw
 
PerlMonks  

Re: Wildcard for key in hash lookup to skip over level

by roboticus (Canon)
on Dec 04, 2012 at 17:38 UTC ( #1007128=note: print w/ replies, xml ) Need Help??


in reply to Wildcard for key in hash lookup to skip over level

ZWcarp

There aren't any wildcards, but you can get a similar effect as the one you stated like this:

my $fl=0; for my $k (keys %{$Pos_overlap{$s[5]}) { ++$fl if exists $Pos_overlap{$s[5]}{$k}{$s[2]}; } if ($fl) {

Not as nice as one would like, but it's the best I can offer at this time.

...roboticus

When your only tool is a hammer, all problems look like your thumb.


Comment on Re: Wildcard for key in hash lookup to skip over level
Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (4)
As of 2014-09-20 00:20 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    How do you remember the number of days in each month?











    Results (151 votes), past polls