What is the best case and worst case complexity of binary search ?
A
O(log n), O(n)
B
O(log n), O(log n)
C
O(1), O(1)
D
O(log n), O(1)
Answer:
Option D