July 2016 - Paper 2

21:  

Consider the following binary search tree : If we remove the root node, which of the node from the left subtree will be the new root ?


21193
A.

11

B.

12

C.

13

D.

16

 
 

Option: D

Explanation :

Click on Discuss to view users comments.

Write your comments here:



22:  
Consider the following operations performed on a stack of size 5 :
 
Push (a); Pop() ; Push(b); Push(c); Pop();
 
Push(d); Pop();Pop(); Push (e)
 
Which of the following statements is correct ?
A.

Underflow occurs

B.

Stack operations are performed smoothly

C.

Overflow occurs

D.

None of the above

 
 

Option: B

Explanation :

Click on Discuss to view users comments.

Write your comments here:



23:  
Suppose you are given a binary tree with n nodes, such that each node has exactly either zero or two children. The maximum height of the tree will be
A. (n/2)-1
B. n/2 +1
C. (n-1)/2
D. (n + 1)/2
 
 

Option: C

Explanation :

Click on Discuss to view users comments.

Write your comments here:



24:  

Which of the following is not an inherent application of stack ?

A.

Implementation of recursion

B.

Evaluation of a postfix expression

C.

Job scheduling

D.

Reverse a string

 
 

Option: C

Explanation :

Click on Discuss to view users comments.

Write your comments here:



25:  
In how many ways can the string
 
A ∩ B – A ∩ B – A
 
be fully parenthesized to yield an infix expression ?
A.

15

B.

14

C.

13

D.

12

 
 

Option: B

Explanation :

Click on Discuss to view users comments.

Write your comments here: