How to implement heap sort? [Solved] | Sololearn: Learn to code for FREE!
+ 2

How to implement heap sort? [Solved]

What am I missing in my heapify stage of heap sort algo? First index should hold the maximum value after heapifying stage but it doesn't happens in my case , any help is appreciated https://code.sololearn.com/c7PdG0Ga1AGE/?ref=app Edit:by mistake I was checking for if a[left]>a[index] tho it should be a[left]>a[largest]

6th Oct 2020, 1:07 PM
Abhay
Abhay - avatar
2 ответов
+ 1
https://youtu.be/HqPJF2L5h9U I think this will help
6th Oct 2020, 7:54 PM
Adarsh Kunwar
Adarsh Kunwar - avatar
8th Oct 2020, 11:14 AM
Abhay
Abhay - avatar