Question: * * Please draw proper diagrams and binary tables and please solve on paper so I can understand better. Heap: is an implementation strategy, usually

**Please draw proper diagrams and binary tables and please solve on paper so I can understand better.
Heap: is an implementation strategy, usually applied to trees to describe certain ordering
properties. It is often used to implement priority-weighted structures, as it has certain
efficiencies over other approaches. These questions concern Heap as a binary tree, the heap
property, and its efficiencies as a sorting algorithm.
Using a suitable set of diagrams and a brief explanation of the steps between your
diagrams, show how a binary tree would be built for the following sequence of
numbers such that the final tree adheres to the max heap property: (3,4,14,2,15)
Using your answer to part (a) as an example, demonstrate how a heap can be stored
in an array. You should provide a diagram showing the placement of theitems in
the array in relationship to the heap tree, and explain the formulae you'd use to
find a parent, the left child and right child (if they exist) of any given node in the
array by their indices.
Quantify and compare the performance of heap-sorting with another less-
efficient list sorting method of your choice and discuss the reasons behind the
performance difference.
 **Please draw proper diagrams and binary tables and please solve on

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!