3.9. Loop complexity

So the loop repeats log(n)* where n is defined to be the initial value of last-first. The loop complexity is therefore (log n)*O(1) = O(log n)


In the Forum:

(no threads at this time)