CSci 5421: Practice Questions for Final Exam
Note:
These questions pertain to material beyond the syllabus for the second Midterm. The
syllabus for the Final includes
all
topics covered in the course, however, so be sure to review earlier
material also.
1. (a)
Show the tree that results from the insertion of key 5 into the splay tree below. Show
intermediate steps.
10
/ \
9
13
/
/
3
11
/ \
\
2
8
12
/
/
1
6
\
7
(b)
Show the Fibonacci heap which results from performing a
FibHeapExtractMin
operation
(also called
DeleteMin
in class) on the Fibonacci heap,
h
, below. (Here ‘*’ denotes a marked
node.) Show intermediate steps, including the auxiliary array
A
[0 :
D
(
n
)] and marked nodes
clearly. (Take
D
(
n
) = 4.)
For consistency, do consolidation starting from the root to the right of
the minimum node, i.e., from 4.
h
\
1
4*
_ 3 _
/  \
/ / \ \
*2 13* 9
5 6 10* 7

/ \

8
12 11
14
2.
For this problem, you will ±nd it useful to review Ch. 6 (either edition). In that chapter, it
is shown that a maxheap,
This preview has intentionally blurred sections. Sign up to view the full version.
View Full Document
This is the end of the preview.
Sign up
to
access the rest of the document.
 Fall '08
 Sturtivant,C
 Algorithms, Data Structures, Fibonacci heap, intermediate steps, Amortized analysis, Potential method, previously marked node

Click to edit the document details