Beefy Boxes and Bandwidth Generously Provided by pair Networks
Think about Loose Coupling
 
PerlMonks  

Re: Check for existance in a hash of hashes

by PrakashK (Pilgrim)
on Mar 27, 2002 at 19:03 UTC ( #154768=note: print w/ replies, xml ) Need Help??


in reply to Check for existance in a hash of hashes

sub print_data { my %hoh = %$skip_users; next if ((exists $hoh{$user}) && (exists $hoh{$user}{$command})); }
I wonder if the next if ... part is a typo. This should throw up an error unless print_data is called inside a loop.

Do you mean:

print $hoh{$user}{$command} if ((exists $hoh{$user}) && (exists $hoh{$user}{$command}));

/prakash


Comment on Re: Check for existance in a hash of hashes
Select or Download Code

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others meditating upon the Monastery: (2)
As of 2014-07-26 08:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    My favorite superfluous repetitious redundant duplicative phrase is:









    Results (175 votes), past polls