Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re^4: scanning hash

by bageler (Hermit)
on Aug 01, 2004 at 15:06 UTC ( #379085=note: print w/ replies, xml ) Need Help??


in reply to Re^3: scanning hash
in thread scanning hash

need to change that slightly so it will return true if all the keys are undef:

return 0 unless defined $_ ? $_ eq $value : defined $value ? 0 : 1


Comment on Re^4: scanning hash
Download Code
Re^5: scanning hash
by Aristotle (Chancellor) on Aug 01, 2004 at 15:09 UTC

    No, I don't.

    $ perl -le'print undef eq undef' 1

    Update: oh, I see what made you think that. I had to NOT my XOR condition. I forgot that XOR produces false rather than true if both operands are equal.

    Makeshifts last the longest.

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others pondering the Monastery: (3)
As of 2014-09-20 05:10 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

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











    Results (153 votes), past polls