Data Structure Questions and Answers-Binary Tree Properties

 

 Buy/Download all MCQ Ebook   >>>Click Here<<<

Data Structure Questions and Answers-Binary Tree Properties

Click on any option to know the CORRECT ANSWERS

Question 1
The number of edges from the root to the node is called ..... of the tree.
A
Height
B
Depth
C
Length
D
None of the mentioned
KBC Questions answers

Question 1 Explanation: 
None.

Question 2
The number of edges from the node to the deepest leaf is called ..... of the tree.
A
Height
B
Depth
C
Length
D
None of the mentioned
Aptitude test Questions answers

Question 2 Explanation: 
None.

Question 3
What is a full binary tree?
A
Each node has exactly zero or two children
B
Each node has exactly two children
C
All the leaves are at the same level
D
Each node has exactly one or two children
EVS Questions answers

Question 3 Explanation: 
None.

Question 4
What is a complete binary tree?
A
Each node has exactly zero or two children
B
A binary tree, which is completely filled, with the possible exception of the bottom level, which is filled from right to left
C
A binary tree, which is completely filled, with the possible exception of the bottom level, which is filled from left to right
D
None of the mentioned
Aptitude test Questions answers

Question 4 Explanation: 
None.

Question 5
What is the time complexity for finding the height of the binary tree?
A
h = O(loglogn)
B
h = O(nlogn)
C
h = O(n)
D
h = O(log n)
Reading comprehension Questions answers

Question 5 Explanation: 
The nodes are either a part of left sub tree or the right sub tree, so we don't have to traverse all the nodes, this means the complexity is lesser than n, in the average case, assuming the nodes are spread evenly, the time complexity becomes O(n).

There are 5 questions to complete.

 

 Buy/Download all MCQ Ebook >>>CLICK HERE<<<