Priority Queue Using Binary Heap

แชร์
ฝัง
  • เผยแพร่เมื่อ 29 ส.ค. 2024
  • A priority queue is an abstract data type that serves an item with high priority before an item with low priority. In another word, it facilitates accessing the item with maximum weight.
    It has been used in many applications, for example, operation systems use it to find out which process has the highest priority to be scheduled or it can be used in implementing Dijkstra's algorithm or even Huffman coding.
    Most programming languages have a priority queue in their standard library, in Java, PriorityQueue is part of “java.util”, python has it under “heapq” and in C++, it’s “std::priority_queue” is in the queue header file.
    Priority queue can be implemented by different data structures, but the most common and efficient implementation is based on the max binary heap. Max binary heap is a complete binary heap that which each node is greater than or equal to its children, so the root of the tree is always the max.
    ___________________________________
    Music from Free To Use Music
    Track: Joy by Limujii
    • Limujii - Joy [FTUM Re...
    ___________________________________

ความคิดเห็น • 5

  • @simoonthrive7576
    @simoonthrive7576 2 ปีที่แล้ว +3

    brief and very helpful, thanks.

    • @bigocast
      @bigocast  2 ปีที่แล้ว

      Glad it was helpful!

  • @monikamoni9459
    @monikamoni9459 ปีที่แล้ว +2

    sir please do such sorts for artificial intelligence and machine for easy understanding and quick access...

  • @IshaXbollywood
    @IshaXbollywood 8 หลายเดือนก่อน

    Thanks🌹❤

  • @stanislavchernyshov7916
    @stanislavchernyshov7916 11 หลายเดือนก่อน

    Golden