Tautology is False
If a
, b
, and c
are boolean values, then (a != b && b != c) => a == c
is an obvious tautology. This however is not true in Javascript since even if we could restrict the types of our functions to be booleans, the existence of null
and undefined
values undermine this:
a = true;
b = false;
c = null;
// Equivalent to (a != b && b != c) => a == c
console.log(!(a != b && b != c) || (a == c)); // outputs false