Contents

What will be the total number of max comparisons if we run brute-force maxima algorithm with n elements?
a) n^2                                   
b) n^n/2
c) n                                        
d) n^8

a

Is a graphical representation of an algorithm?
a) Sigma Notation              
b) Theta Notation
c) Flowchart                       
d) Asymptotic notation

c

It is called Heapify. (In other books it is sometimes called sifting down.)?
a) True                                 
b) False
c) NA                                     
d) NA

a

There is one principal operation for maintaining the heap property?
a) Heapify Procedure      
b) Heaney Program
c) Heapify Routine            
d) none

a

The root is at position 1 of the array?
a) True                                 
b) False
c) NA                                     
d) NA

a

Access to nodes involves simple arithmetic operations: shown in below left(i): returns 2i, index of left child of node i. right(i): returns 2i+1, the right child. parent(i): returns bi/2c, the parent of i.?
a) True                                
b) False
c) NA                                     
d) NA

a

Contents Details