Two balanced binary trees are given with m and n elements respectively. They can be merged into a balanced binary search tree in ____ time.

Q & ACategory: Data StructureTwo balanced binary trees are given with m and n elements respectively. They can be merged into a balanced binary search tree in ____ time.
Admin Staff asked 4 years ago

Two balanced binary trees are given with m and n elements respectively. They can be merged into a balanced binary search tree in ____ time.
a) O(m+n)
b) O(mn)
c) O(m)
d) O(mlog n)

1 Answers
Admin Staff answered 4 years ago

a) O(m+n)