by tgv · 6mo ago · 0 comments
Why? Boolean logic is older than its namesake, George Boole (1815-1864). Syllogisms are ancient. And we've had ternary systems, as well as others.
And what does the third value represent? True and false are pretty universal when it comes to predicates, but anything in between is rather subjective.
enum Bool
{
True,
False,
FileNotFound
};
https://thedailywtf.com/articles/What_Is_Truth_0x3f_So, in terms of radix economy, ternary computing is the most efficient, but you're leaving information density unused if you use it for binary, and representing ternary with binary is inherently inefficient.
Not that there's anything wrong with having an extra value "unknown", but it doesn't fundamentally alter the logic. As unknown in most cases means "it will be true or false at some point", its usage in computing is that of a singleton (who needs a word with 64 potentially unknown bits?), so dealing with unknown values as an exception is easier than permeating hardware with it. Using ternary to represent unknown is just not efficient.