3 ms·
>Every ANSI compliant C library comes with an implementation of a quicksort routine Actually the standard doesn't require qsort() to be quicksort. For example,
by cremno 12y ago
>Every ANSI compliant C library comes with an implementation of a quicksort routine
Actually the standard doesn't require qsort() to be quicksort. For example, musl's implementation uses the smoothsort algorithm.
http://port70.net/~nsz/c/c11/n1570.html#7.22.5.2 http://port70.net/~nsz/c/c11/n1570.html#7.22.5.2
http://git.musl-libc.org/cgit/musl/tree/src/stdlib/qsort.c?id=aee9b1526247f74e9b755b50e102b3b4ce2aac1d http://git.musl-libc.org/cgit/musl/tree/src/stdlib/qsort.c?i...