Beefy Boxes and Bandwidth Generously Provided by pair Networks
P is for Practical
 
PerlMonks  

Re: Wrong Results in checking if hash value is defined or not

by sundialsvc4 (Abbot)
on Jun 30, 2017 at 14:54 UTC ( #1193939=note: print w/replies, xml ) Need Help??


in reply to Wrong Results in checking if hash value is defined or not

From perldoc perlfunc, on the entry for “defined()”:

When used on a hash element, it tells you whether the value is defined, not whether the key exists in the hash.   Use "exists" for the latter purpose.

  • Comment on Re: Wrong Results in checking if hash value is defined or not

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://1193939]
help
Chatterbox?
and all is quiet...

How do I use this? | Other CB clients
Other Users?
Others rifling through the Monastery: (9)
As of 2017-11-23 21:35 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?
    In order to be able to say "I know Perl", you must have:













    Results (340 votes). Check out past polls.

    Notices?