Today, I realized that !=
and <>
can be different.
Of course, they are equivalent in the ideal domain, but we live in a polymorphic world where two values can be incomparable with each other.
For example, 1
, a number, is incomparable to "Hello"
, a string of text.
This relation is mathematically known as a Partial Ordering.
Arguably, "Hello"
doesn’t literally equal one, which we can denote as "Hello" ≠ 1
.
On the other hand, "Hello" ≶ 1
doesn’t quite hold.
Their mutual incomparability means that neither is less or greather than the other; it would instead be "Hello" ≸ 1
.