table of contents
HSORT(3) | Library Functions Manual | HSORT(3) |
NAME¶
hsort - array heap sort
SYNOPSIS¶
#include <ast.h> void strsort(char** array, int elements, int (*compare)(const char* a, const char* b));
DESCRIPTION¶
strsort does a heap sort on the array of pointers array with elements elements using the comparison function compare. compare returns -1 if a is lexicographically less than b, 0 if a is equal to b, and 1 if a is lexicographically greater than b.