Beefy Boxes and Bandwidth Generously Provided by pair Networks
No such thing as a small change
 
PerlMonks  

Re: why direct undef comparison isn't working

by MidLifeXis (Monsignor)
on Dec 10, 2014 at 14:16 UTC ( [id://1109906]=note: print w/replies, xml ) Need Help??


in reply to why can't compare a variable with undef directly?

The value undef means that there is no defined value. If two somethings have not been defined, that does not make them equal.

Consider how you would get from point A to point B, and point A to point C. Until you know where they are, road conditions, method of travel, number of passengers, and so on, the details of travel to both locations are undefined. That does not make them equal.

If you squint hard enough, it can be compared to a NULL value in SQL.

--MidLifeXis

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others pondering the Monastery: (8)
As of 2024-04-23 19:09 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found