Question: Which of the following algorithm structures would lead to the recurrence equation T ( n ) = 2 T ( n / 2 ) +

Which of the following algorithm structures would lead to the recurrence equation T(n)=2T(n/2)+O(n), for the worst-case time cost on data of size n?
Group of answer choices
Using linear effort (proportional to size), reduce the amount of data by one, solve the reduced problem recursively,and then do linear work to adjust the result of the recursive call to give the result on the full input.
Using linear effort (proportional to size), divide the data in half, solve both halves recursively, and then do linear work to combine the result of the recursive calls to give the result on the full input.
Using linear effort (proportional to size), divide the data in half, choose one half to solve recursively, and then do linear work to adjust the result of the recursive call to give the result on the full input.
Using constant effort (independent of size), divide the data in half, solve both halves recursively, and then do constant work to adjust the result of the recursive call to give the result on the full input.

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 Programming Questions!