If I apply master theorem to the following recurrence -
2(n/2) + 2
Then I should get (n logn) time complexity correct?
My professor says that the time complexity is theta(n), not theta(n logn).
She says the exponent on the 2 is 0, not 1. Makes no sense.
Should I post my algorithm? It is a divide and conquer that finds the position of the largest element in an array of integers.
2(n/2) + 2 = n + 2
fuck off
do your own homework, Tyrone
>>53504040
I already did my homework bitch. I have a disagreement with my professor and am asking /g/ comp-sci bros who is right.
>>53503955
This isn't algebra. It's a recurrence relation for time complexity of an algorithm. I thought /g/ was filled with computer scientists.
Your professor is right
>>53504564
What are you even trying to say? It's O(n)
>>53503804
>algorithm that finds the largest integer
This shouldn't be anything more than (n) time m8
>>53503804
2^1*2^-1=2^0
>divide and conquer to find the largest int in an array
Pajeet, my son....
>>53503804
Youre wrong, kid
>>53503804
>master theorem
>master
This kind of terminology is oppressive and needs to be changed.