There are even more algorithms to sort elements. For example, the heap algorithms are provided
to call the functions that implement a heap directly (a heap can be considered as a binary tree
implemented as sequential collection). The heap algorithms are provided and used as the base for
efficient implementations of priority queues (see Section 12.3, page 641). You can use them to sort
all elements of a collection by calling them as follows