-->
当前位置:首页 > 题库

单选题:The time complexity of traversing a binary tree with $$N$$ nodes

Luz5年前 (2021-05-10)题库1235
The time complexity of traversing a binary tree with $$N$$ nodes and height $$H$$ in levelorder (with the help of with an auxiliary queue) is __. @[A](3)

A. $$O(N)$$
B. $$O(H)$$
C. $$O(N\log H)$$
D. $$O(H+N)$$




A.$$O(N)$$
B.$$O(H)$$
C.$$O(N\log H)$$
D.$$O(H+N)$$


答案:A