University of California, Santa Cruz

Prof. Paulo Franca - Spring 2000

Introduction

Syllabus

Guidelines for labs

Lab sections

Take quiz & check grades

Properties:

bulletheight of the heap (maximum distance from a node to the root) is TETA(lg n)
bulletsince the heap is based on a complete binary tree.
bulletmost operations run in time proportional to the height of the tree, therefore O(lg n)

Structure:

typedef struct
{
   recordtype array[N];
   int heapsize;
   int arraysize;
}aheap;