PROBLEM SET 2

Draw the heap produced when the keys S I M P L E Q U E S T I O N are built into heap using the bottom-up construction method.



How many 2-by-2 merges are done by recursive mergesort when called on a file of size 39? By bottom-up mergesort?



Draw the binomial queue that results when the keys E A S Y Q U E S T I O N are inserted in that order into an intially empty binomial queue.



Extra Credit. Which array positions could possibly be occupied by the third largest element in a heap of size 2^n (with n>3)? By the third smallest element?



Due: Wednesday, February 21