Edit: I'm a Java guy too, don't get why some people get so butthurt over things :)
At least it's not JavaScript with infinity,null,undefined, and NaN. Oh and null!=null which is hilarious
Edit: I'm a Java guy too, don't get why some people get so butthurt over things :)
At least it's not JavaScript with infinity,null,undefined, and NaN. Oh and null!=null which is hilarious
NaN != NaN is surprising, but is not unique to JavaScript. As far as I know, this is the case in every language, and is mandated by the IEEE 754 specification.
However, it does come up in JavaScript more often than other places, since NaN is really easy to get (+{} => NaN, 1 - '' => NaN, etc, etc).
I more of a C++ guy, but I like Java very much and have used it extensively in the past. I personally like a good C/C++ joke and can't understand why the Java devs are so serious. Apparently nobody is allowed to joke about Java, it's serious business :D