Question: Student Number Part A: Complexity 1. [10 marks) What is the worst case complexity for each of the following operations? Put an X in the

 Student Number Part A: Complexity 1. [10 marks) What is the

Student Number Part A: Complexity 1. [10 marks) What is the worst case complexity for each of the following operations? Put an "X" in the box representing the complexity for each operation. If you choose "other", meaning the complexity is something other than the choices listed specify the complexity in the box O(1) Olog n) O(n) O(n log n) (n) Other Sum all the (integer) values contained in a linked list Add a node to a balanced binary search tree. Add a value to the middle of a sorted (regular) python list Perform a quicksort of a python list and then carry out 10 binary searches on this sorted list. Print the first 10 nodes of a linked list Use selection sort to sort N numbers Print all the values of a binary search tree 100 times each Count the number of leaf nodes in a balanced binary search tree Delete a node from somewhere (location unknown) in a linked list Print all the values in a list then use an insertion sort to sort the list

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!