Heap insertion (
Pascal version
available)
siftup( r, i, n ) RecordArray r; int i, n; {ArrayEntry tempr; int j; while ( (j=2*i) <= n ) { if ( j
C
source (513.sift.c)
Pascal
source (513.sift.p)
©
Addison-Wesley
Publishing Co. Inc.