Menu
![]() To compare numbers instead of strings, the compare function can subtract bįrom a. The default lexicographic comparator satisfies all constraints above. ![]() A comparator that always returns 0 will cause the array to not be changed at all, but is reliable nonetheless. ![]() ![]() For example, if a comparator only returns 1 and 0, or only returns 0 and -1, it will not be able to sort reliably because anti-symmetry is broken.
0 Comments
Leave a Reply. |