A ranked set is a data structure for storing and manipulating the smallest stored elements.
RankedSet
The ranked set implementation in Pastel has the following properties:
Task / Property | Complexity |
---|---|
Insert an element. | |
Remove the maximum element. | |
Find out the maximum element. | |
Find out the number of elements in a set. |
std::priority_queue
The ranked-set is a bounded priority-queue. The main difference is that the ranked-set potentially removes an existing element on insertion, if the size already equals capacity.