Priority Queue STL Quiz Q5

For creating a heap of N numbers present in the vector, we need NlogN operations (as insertion of 1 element in heap takes logN time).

Hello @rahul.maheshmaheshwari,

The following link will help you understand this:

1 Like

okay i understood the explanation. Thanks. BTW it was a tricky one :wink: