Answered step by step
Verified Expert Solution
Question
00
1 Approved Answer
Please answer these multiple choice questions. 26. - 36. Answer the following questions based on the binary search tree below: 26. Is this a complete
Please answer these multiple choice questions.
26. - 36. Answer the following questions based on the binary search tree below: 26. Is this a complete binary tree? (a) Yes (b) No 27. What is the root of the tree? (a) 7 (c) 35 (b) 15 (d) 11 28. What is the depth of the tree? (a) 1 (c) 3 (b) 2 (d) 4 29. What is the path taken in order to locate node 14 and identify that it is not in the tree? (a) 7101211 (c) 151012 NULL (b) 71012 NULL (d) 152520 NULL 30. If the value 16 were in the tree, what would its parent be? (a) 15 (c) 12 (b) 7 (d) 20 31. What are the leaves of the tree? (a) 11,22,35 (c) 7,12,20,30,11,22,35 (b) 7,12,11 (d) 7,11,22,35 32. If node 10 is deleted, what node will replace it? (a) 15 (c) 11 (b) 12 (d) NULL 33. What is the order in which these nodes will be visited in a breadth-first traversal? (a) 1510&91211252022302735 (c) 8910111215202225273035 (b) 8911121022202735302515 (d) 1510251220303911222735 34. What is the order in which these nodes will be visited in a pre-order traversal? (a) 15107391211252022302735 (c) 37910111215202225273035 (b) 39711121022202735302515 (d) 15102571220303911222735 35. How long does it take to find a node? (a) O(logn) (c) O(1) (e) O(n) (b) O(n2) (d) O(nlogn) 36. How long does it take to remove a node? (a) O(logn) (c) O(1) (e) O(n) (b) O(n2) (d) O(nlogn)
Step by Step Solution
There are 3 Steps involved in it
Step: 1
Get Instant Access with AI-Powered Solutions
See step-by-step solutions with expert insights and AI powered tools for academic success
Step: 2
Step: 3
Ace Your Homework with AI
Get the answers you need in no time with our AI-driven, step-by-step assistance
Get Started