PHP | Ds\PriorityQueue Functions Complete Reference
PriorityQueue is similar to a Queue data structure. The elements of priority queue are pushes into the queue with a given priority. The highest priority element will always been present at the front of the queue. The priority queue is implemented using the max heap.
Requirements: PHP 7 is required for both extension and the compatibility polyfill.
Installation: The easiest way to install data structure by using the PECL extension.
pecl install ds
The complete list of Ds\PriorityQueue functions are given below: