Table of Contents
Previous Section Next Section

make_heap

template <class RandIter>    void make_heap(RandIter start, RandIter end);
template <class RandIter, class Comp>
    void make_heap(RandIter start, RandIter end, Comp cmpfn);

The make_heap( ) algorithm constructs a heap from the sequence defined by start and end.

The second form allows you to specify a comparison function that determines when one element is less than another.


Table of Contents
Previous Section Next Section