Top 80+ Solved Non Linear Data Structures - Trees MCQ Questions Answer
Q. The binary tree sort implemented using a self – balancing binary search tree takes time isworst case.
a. O(n log n)
b. O(n)
c. O(n2)
d. O(log n)
Q. An AVL tree is a self – balancing binary search tree, in which the heights of the two child sub treesof any node differ by
a. At least one
b. At most one
c. Two
d. At most two
Q. Associative arrays can be implemented using
a. B-tree
b. A doubly linked list
c. A single linked list
d. A self balancing binary search tree
Q. Which of the following is a self – balancing binary search tree?
a. 2-3 tree
b. Threaded binary tree
c. AA tree
d. Treap
Q. A self – balancing binary search tree can be used to implement
a. Priority queue
b. Hash table
c. Heap sort
d. Priority queue and Heap sort
Q. In which of the following self – balancing binary search tree the recently accessed element can beaccessed quickly?
a. AVL tree
b. AA tree
c. Splay tree
d. Red – Black tree
Q. The minimum height of self balancing binary search tree with n nodes is
a. log2(n)
b. n
c. 2n + 1
d. 2n – 1
Q. What is an AVL tree?
a. a tree which is balanced and is a height balanced tree
b. a tree which is unbalanced and is a height balanced tree
c. a tree with three children
d. a tree with atmost 3 children
Q. Why we need to a binary tree which is height balanced?
a. to avoid formation of skew trees
b. to save memory
c. to attain faster memory access
d. to simplify storing
Q. Given an empty AVL tree, how would you construct AVL tree when a set of numbers are givenwithout performing any rotations?
a. just build the tree with the given input
b. find the median of the set of elements given, make it as root and construct the tree
c. use trial and error
d. use dynamic programming to build the tree
Q. What maximum difference in heights between the leafs of a AVL tree is possible?
a. log(n) where n is the number of nodes
b. n where n is the number of nodes
c. 0 or 1
d. atmost 1
Q. What is missing?
a. Height(w-left), x-height
b. Height(w-right), x-height
c. Height(w-left), x
d. Height(w-left)
Q. Why to prefer red-black trees over AVL trees?
a. Because red-black is more rigidly balanced
b. AVL tree store balance factor in every node which costs space
c. AVL tree fails at scale
d. Red black is more efficient
Q. Which of the following is the most widely used external memory data structure?
a. AVL tree
b. B-tree
c. Red-black tree
d. Both AVL tree and Red-black tree
Q. B-tree of order n is a order-n multiway tree in which each non-root node contains
a. at most (n – 1)/2 keys
b. exact (n – 1)/2 keys
c. at least 2n keys
d. at least (n – 1)/2 keys