Question: Write the recurrence relation of the following recursive algorithm. What is the complexity of the algorithm? Fun (n) 1 if n=1 then return 1
Write the recurrence relation of the following recursive algorithm. What is the complexity of the algorithm? Fun (n) 1 if n=1 then return 1 2 return Fun (n-1) + Fun (n/2) 3 end
Step by Step Solution
3.40 Rating (156 Votes )
There are 3 Steps involved in it
To write the recurrence relation for the given recursive algorithm we need to cons... View full answer
Get step-by-step solutions from verified subject matter experts
