BINARY SEARCH TREE
TASK
×
A LITTLE BRAIN TEASER
Q1. What is the speciality about the inorder traversal of BST ?
(A) It traverses in a non increasing order.
(B) It traverses in a increasing order.
(C) It traverses in a random function.
(D) It traverses based on priority of the node
Ans:
Q2. What are the worst case and average case complexity of BST ?
(A) O(n),O(n)
(B) O(logn),O(logn)
(C) O(logn),O(n)
(D) O(n),O(logn)
Ans:
Q3. Which of the traversal outputs the data in sorted order in a BST ?
(A) Preorder
(B) Inorder
(C) Postorder
(D) Level order
Ans:
INSERTION ALGO
DELETION ALGO
PREORDER ALGO
INORDER ALGO
POSTORDER ALGO