Analysis Of Algorithm, Algorithms, Recursion, Recurrence Relation, Discrete Mathematics.
in equation 1, we get: T(n-1) = T((n-1)-1)+1 .:T(n-1) = T(n-2)+1 ... Let's call this equation 2 Now, SUBSTITUTE equation 2 in 1, we get: T(n) = [T(n-2) + 1] + 1 .:T(n) = T(n-2) + 2 ... Let's call this equation 3. Now what does this mean? Well, let’s say if T(n) = T(n-1) + 1before first recursion