Question: Data Structure 6. Consider the following recursive method and BST pictured below public BSTNode mysteryMethod (BSTNodeKey, E> root) f if (root.left ()== null) return root;

6. Consider the following recursive method and BST pictured below public BSTNode mysteryMethod (BSTNodeKey, E> root) f if (root.left ()== null) return root; return mysteryMethod(root.left()); \} (a) What node would be returned if the method is applied to the node with value 13? (b) In general, explain what this method does when applied to the root of a BST, What would be a better name for this method? (i.e., suggest a relevant name that indicates what it actually does.) 17. Suppose that the data below are stored in an array {3,6,0,7,4,1,9,5,2,8} Show the max-heap that results from running buildheap on this array. 18. [15 points] static > void inssort (E[] A) f for(int i=1;i
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
