Priority queue implemented as min-heap (dequeueing on basis of priority only; FIFO not guaranteed)
In my A level Computer Science class, we learnt about priority queues, but every implementation that was shown used a simple array, requiring enqueue operations with a worst-case time complexity of
Turns out, C# uses a min-heap data structure instead- it can be stored as a simple array but the enqueueing and dequeueing has a worst case time complexity of