单选题:The space complexity of recursively traversing a binary tree wit
The space complexity of recursively traversing a binary tree with $$N$$ nodes and height $$H$$ in preorder is __. @[B](3)
A. $$O(\log N)$$
B. $$O(H)$$
C. $$O(N)$$
D. $$O(H+N)$$
A.$$O(\log N)$$
B.$$O(H)$$
C.$$O(N)$$
D.$$O(H+N)$$
答案:B
A. $$O(\log N)$$
B. $$O(H)$$
C. $$O(N)$$
D. $$O(H+N)$$
A.$$O(\log N)$$
B.$$O(H)$$
C.$$O(N)$$
D.$$O(H+N)$$
答案:B