I was just wondering if this was possible?Surely there maybe some naive methods of doing so, but I was just wondering if someone can suggest efficient ways to do so.
Is it possible to convert a Max heap to a Min heap in place?
ds.algorithms;ds.data structures
You can just ignore that you have a max heap and build your min heap from it. O(n) timecomplexity. No need for additional array.