I like Serena
Science Advisor
Homework Helper
MHB
- 16,335
- 258
evinda said:Will the resursion-tree be like that?
View attachment 3390
If so, for which value of $n$ will it end? And how can I find the last value that it will take? (Thinking)
It would help if you specify at each level the fraction of $n$. (Worried)
At the top level you are calculating for $T(n)$.
One level down for $T(\lfloor\frac n 2\rfloor)$.
Etcetera, until we get to $T(0)$ for which the cost is $2$.
To get a sense of this, perhaps we can pick an example for say $n=8$. (Mmm)
And perhaps another one for $n=11$.