codingsorting
A comparator needs a consistent ordering
Anonymous
if a < b and b < c, the relation should also put a before c. Contradictory comparisons can make sorting behavior unreliable. When two records tie on one field, use a deliberate tie-break rule if the required order needs one.
0