Conditional XOR?

Conditional xor should work like this:

true xor false = true
true xor true = false
false xor true = true
false xor false = false

But this is how the != operator actually works with bool types:

(true != false) // true
(true != true) // false
(false != true) // true
(false != false) // false

So as you see, the nonexistent ^^ can be replaced with existing !=.

Leave a Comment