Podcast
Questions and Answers
What is the time complexity of the recursive binary search algorithm?
What is the time complexity of the recursive binary search algorithm?
- $O(n^2)$
- $O(\log n)$ (correct)
- $O(2^n)$
- $O(n)$
In the recursive Fibonacci algorithm, what is the lower bound on the time complexity T(n)?
In the recursive Fibonacci algorithm, what is the lower bound on the time complexity T(n)?
- $O(2^n)$ (correct)
- $O(n \log n)$
- $O(fibonacci(n))$
- $O(n^2)$
What value does k take when the base case is reached in the recursive binary search algorithm?
What value does k take when the base case is reached in the recursive binary search algorithm?
- $k = n/2$
- $k = 0$
- $k = \log n$ (correct)
- $k = 1$
What is the recurrence relation for the running time of the recursive binary search method?
What is the recurrence relation for the running time of the recursive binary search method?
What is the big-O complexity of the recursive selection sort algorithm?
What is the big-O complexity of the recursive selection sort algorithm?
Which method is used to solve the recurrence relation representing the running time of recursive methods?
Which method is used to solve the recurrence relation representing the running time of recursive methods?
What is the base case for the given recursive Fibonacci function?
What is the base case for the given recursive Fibonacci function?
Which algorithm does the given recurrence relation correspond to?
Which algorithm does the given recurrence relation correspond to?
In the master method, what does 'a' represent in the recurrence relation?
In the master method, what does 'a' represent in the recurrence relation?
What does the overhead function 'f(n)' represent in the master method?
What does the overhead function 'f(n)' represent in the master method?
Flashcards are hidden until you start studying