How to represent a Binary Heap in Java? | Animation

Поділитися
Вставка
  • Опубліковано 9 лис 2024

КОМЕНТАРІ • 14

  • @itsdineshvaryani
    @itsdineshvaryani  3 роки тому +1

    Please *Like* , *Comment* , *Share* , *Subscribe* and *Click Bell* 🔔🔔🔔 Icon for More Updates. To get *Data Structures and Algorithms* complete course for free please follow this link - ua-cam.com/play/PL6Zs6LgrJj3tDXv8a_elC6eT_4R5gfX4d.html

  • @shubhamagarwal1941
    @shubhamagarwal1941 2 роки тому +2

    Best series for DS & Algo. I am also 10 yrs java exp guy. Was looking for DS & Algo free course over UA-cam with java implementation and found this. Hats Off To You Man...Excellent Work. GOD BLESS YOU :)

  • @prakritilodhi7743
    @prakritilodhi7743 Місяць тому

    Nice explanation 😊

  • @ABHISHEKAnand-ut2fq
    @ABHISHEKAnand-ut2fq 3 роки тому +3

    thank you sir for your effort... really helpful!!!

    • @itsdineshvaryani
      @itsdineshvaryani  3 роки тому +1

      In case you like this video ... Please like, share and subscribe so that channel grows and it allows me to post more ... Thanks !!!

  • @anuragpandey796
    @anuragpandey796 2 роки тому +3

    What if 1 is empty in the above max heap, according to definition left side should always be filled, so if we take out 1 we will fulfill the definition but one place in array will be empty.

    • @itsdineshvaryani
      @itsdineshvaryani  2 роки тому +1

      you can also fill 0 index .... you just need to change formulas for parent and child accordingly !!!

  • @VikasSingh-wp9mv
    @VikasSingh-wp9mv 2 роки тому +1

    your videos contains great sir

  • @ekansh6267
    @ekansh6267 Рік тому

    👌👌👍

  • @arijitmohapatra147
    @arijitmohapatra147 3 роки тому +1

    Why we r storing elements from index 1??

    • @itsdineshvaryani
      @itsdineshvaryani  3 роки тому +1

      It makes calculation of both child indexes easy and also if given child index we can calculate easily where parent index lies... You can start heap from 0 index as well but google child and parent index calculation correspnding to 0 index ....

    • @arijitmohapatra147
      @arijitmohapatra147 3 роки тому +1

      @@itsdineshvaryani ok sir, thanks for replying always 🙏🙏
      Only UA-camr who always replies within a second🔥🎉❤️