Question: Question 3 40 pts Provide a short answer to the following questions. The universe of algorithms is what we have done in class so far.
Question 3 40 pts Provide a short answer to the following questions. The universe of algorithms is what we have done in class so far. Use appropriate asymptotic notation as introduced in class. (1) Give the running time of InsertionSort for sorting $\sqrt(n)$ keys. (sqrt() is the square root function.) (2) Give the running time of MergeSort for sorting $m-2/ Vigim}$ keys. (3) Give the running time of Binary Search on a sorted sequence of $2"q-1$ keys. (4) Give the running time of Union-Find that involves $n$ elements, $n/lgin)$ Union operations, $n$ MakeSet operations and $5$ Find operations. (5) In Input DECR how many comparisons does InsertionSort perform? (6) In Input DECR how many comparisons does SelectionSort perform? (7) Give the running time of Hash Search operation in collision resolution by open addressing. The number of slots in the hash table is N and the number of keys already inserted is n, where n
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
