Ternary comparison
= Ternary comparison
A single comparison returning one of three outcomes: less than, equal to, or greater than. A <comparison model> may count this as one operation even when a programming language expresses the outcomes using multiple Boolean tests. <Binary search> on ordered keys uses one such comparison per inspected position.