Question: [11 marks] a. Based on Figure 1, answer the following questions. 70 40 85 20 60 81 89 15 27 86 96 Figure 1 Height

 [11 marks] a. Based on Figure 1, answer the following questions.

[11 marks] a. Based on Figure 1, answer the following questions. 70 40 85 20 60 81 89 15 27 86 96 Figure 1 Height of the tree ii. Level of node 60 ii. Depth of node 86 liv. How many descendant of node 40? v. Give the order of node visited in a in-order traversal. (NOTE: Write your answer(node) with separated by one blank space/whitespace only: Jeg 3035) vi. Give the order of node visited in a pre-order traversal.(NOTE: Write your answer(node) with separated by one blank space/whitespace only: w.9 30 35) vii. Give the order of node visited in a post-order traversal.(NOTE: Write your answer(node) with separated by one blank space/whitespace only: e.g 30 35) viii. State whether the binary search tree drawn in x) is full and/or complete b. Based on Figure 1 answer the following questions which are executed in sequence. [ 4 marks] i. Suppose we insert a new node 77, what will be the parent of node 772 ii. Suppose we insert a new node 24, what will be the parent of node 24? iii. Suppose we remove the root node, what will be the new root? iv. Suppose we remove the node 85, what will be parent of node 81 and 89

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!