Dds Assignment 3
Dds Assignment 3
Short Questions.
SR.No Question
1. Define: Height of a tree.
2. What is common in inorder, preorder and postorder traversal?
3. The height of a binary tree is the maximum number of edges in any root to leaf path. The maximum
number of nodes in a binary tree of height n are?
4. The in-order traversing of binary search tree is always in _____________ order.
5. A Binary tree has 30 leaves. How many number of nodes will be there in tree having two children?
(a) 28 (c) 31
(b) 32 (d) 29
6. Total no of nodes in the binary tree of having height h.
7. What is the height of an AVL tree with n nodes?
8. What is the time complexity of searching in an AVL tree?
9. What triggers a double rotation in an AVL tree?
10. What are the four types of rotations used in AVL trees?
11. Why is balancing important in an AVL tree?
MCQ Questions:
1. What is the height of a tree with only one node?
a) 0 b) 1 c) -1 d) 2
2. Which of the following traversals would give the elements of a binary search tree in sorted order?
5. Which traversal technique can be performed efficiently on a threaded binary tree without recursion or a
stack?
A) Preorder traversal
B) Inorder traversal
C) Postorder traversal
D) Level-order traversal