Friday, January 11, 2013

6-2-4


What is the effect of calling MAX-HEAPIFY.A; i / for i > A.heap-size/2?
No effect. Since for i > A.heap-size/2 are leaves of the tree. Remember $\lfloor n/2 \rfloor+1 ,\lfloor n/2 \rfloor+2...n$ are all leaves.

No comments:

Post a Comment