In this project, you are required to implement a set of min-heap operations in ARM assembly
language. You will use KEIL simulator to develop and test your code.
First of all, you will implement the min-heap data structure (which has the logical structure of
a nearly complete binary tree) as an array of 32-bit integers. The first element in the array A[0]
is the size of the heap, i.e. the number of elements in the heap (i.e the integer “size”) is in
A[0]. The rest of the elements in A (A[1] to A[size]) are the values in the nodes of the binary
tree.
Fundamental property of a min-heap is that for every node i other than the root, A[parent(i)]
≤ A[i], that is, the value of a node is at most the value of its parent. If a node is at the kth
location in the array, its children will be at the (2k) and the(2k+1) locations of the array. The
following figures gives three different min-heaps which have 6, 4 and 3 nodes.