A Comparator may compare objects as equal (return zero), even if they
are distinct objects.
The sort function is not guaranteed to be stable, so distinct objects
that compare as equal may occur in any order in the result: