PRIORITY QUEUE

An unsorted priority queue is one in which we insert at the end and remove elements based on priority(i,e; smallest value in the queue). The unsorted priority queue makes adding very fast - add operations are O(1), because items are just added to the end of the list, in no particular order.

A sorted priority queue is one in which we insert at the position and remove elements based on priority(i,e; smallest value in the queue). The sorted priority queue makes deleting and finding minimum value very fast - delete and peek operations are O(1), because items are just deleted from the end of the list, in no particular order.

×

Navigate through sections to change simulation.

MIN
-
-
LEN
-
Seek to change Speed