I'm new to js and I wonder if there is a XNOR operator in JS. I tried !(a^b)
but it gives weird result. For example:
var a,b="aa";
a^b
this code returns true, however, I XNOR returns false.
UPDATE
I need to return true if the two operand are true(different from false values), or the two are false (both equals to : null, undefined,""-empty string- or 0)
==
? – Islamvar a,b="aa"; a^b
? It looks completely wrong and doesn't give true at all. – Hyphenated