GATE CSE Trees – Data Structures Practice Test | Set 1

Questions 1-5 of 100

0% completed (0/100 answered)
Your score 0/100 0 answered
Correct 0 Incorrect 0 Unanswered 100 Accuracy 0%

Question 1

MCQ · Single Correct 1 mark

The height of a tree is the length of the longest path from the root to a leaf. What is the maximum number of nodes in a binary tree of height h (where height of a single node tree is 0)?

Answers for question 1

Question 2

MCQ · Single Correct 2 mark

Postorder traversal of a given binary search tree T produces: 10, 20, 15, 30, 25. Which of the following is the preorder traversal of T?

Answers for question 2

Question 3

MCQ · Single Correct 2 mark

The preorder traversal sequence of a binary search tree is 30, 20, 10, 15, 25, 40, 35, 50. Which of the following is the postorder traversal sequence?

Answers for question 3

Question 4

MCQ · Single Correct 2 mark

Suppose the numbers 7, 5, 1, 8, 3, 6, 0, 9, 4, 2 are inserted in that order into an initially empty Binary Search Tree. What is the height of the binary search tree (where height is the number of edges on the longest path from root to leaf)?

Answers for question 4

Question 5

MCQ · Single Correct 1 mark

For a full binary tree (every node has either 0 or 2 children), which additional traversal, when paired with a given preorder traversal, is sufficient to uniquely reconstruct the tree?

Answers for question 5
Scroll to Top