Question: a question in algorithm .A co mputer science professor proposed using trinary search - in which the list is split into segments -to improve on
a question in algorithm 
.A co mputer science professor proposed using "trinary search" - in which the list is split into segments -to improve on the binary search algorithm on a sorted list. Part of his pro code appears below. rinarysearch (int value, int[1 a, int highIndex, int lowIn return1 int midIndex1 = (lowindex + high Index) /3; if (lowIndex > highIndex) // not found else int midIndex2 2*(1owindex + highIndex) /3; YOUR CODE TO cOMPLETE THE ALGORITHM GOES HERE!! a. Write the missing code in the algorithm above. Write a recurrence relation for the time complexity of your algorithm, and solve i the time complexity. Is the professor's proposed trinary search algorithm a substantial improvement c search? Explain why or why not
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
