[algorithm] Big-oh vs big-theta