Contents

Define the.........of an element to be one plus the number of elements that are smaller.
a) Rank                                                
b) Degree
c) NA                                     
d) NA

a

MERGE-SORT( array A, int p, int r) 1 if (p<r)2 then 3q (p+r)/24 Merge-Sort (A,p,q) // sort A[p..q] 5 Merge-Sort (A, q+1, r) // sort A[q+1..r] 6 MERGE (A, p,q,r)// Merge the two pieces?
a) True                                 
b) False
c) Nan                                   
d) NA

a

The merge sort algorithm works by.......
a) divide: split down the middle into two subsequences, each of size roughly n/2
b) Conquer: sort each subsequence by calling merge sort recursively on each
c) Combine: merge the two sorted subsequences into a single sorted list
d) All of the above

d

The main elements to a divide-and-conquer solution are....
a) Divide: the problem into a small number of pieces
b) Conquer: solve each piece by applying divide and conquer to it recursively
c) Combine: the pieces together into a global solution
d) All of the above

d

Ancient Roman politicians followed an important principle of good algorithm design known as Divide and Conquer Strategy?
a) True                                 
b) False
c) NA                                     
d) N/A

a

Upper bound f(n) grows no faster asymptotically than n^2?
a) True                                 
b) False
c) NA                                     
d) NA

a

Contents Details