Question: Say we have a heap priority queue implementation and its array is currently 51 46 34 31 39 29 7 14 3 1 35 2 How will it look after we insert 42?
51 46 34 31 39 29 7 14 3 1 35 2
Answer:
51 46 42 31 39 34 7 14 3 1 35 2 29