我的教授刚刚告诉我们,任何将输入长度减半的操作都有一个O(log(n))复杂度作为拇指规则.为什么不是O(sqrt(n)),它们都不是等价的?
algorithm time-complexity
algorithm ×1
time-complexity ×1