What is the primary advantage of using a BST over a sorted array for storing data when frequent insertions and deletions are required?
BSTs use less memory.
BSTs handle insertions and deletions more efficiently.
BSTs offer faster search times.
BSTs are easier to implement.
What is the worst-case time complexity for searching for a node in a balanced binary tree?
O(n)
O(log n)
O(n^2)
O(1)
In the context of BST insertion, where is a new node with a key smaller than all existing keys typically inserted?
As the new root
As the right child of the rightmost node
As the left child of the leftmost node
The position depends on the specific implementation
Nodes that share the same parent are called:
Descendants
Siblings
Ancestors
Cousins
A node's direct descendant in a binary tree is called its:
Ancestor
Child
Sibling
Parent
A complete binary tree with 'n' nodes will always have a height of:
log2(n)
n/2
n
floor(log2(n)) + 1
Which traversal technique is typically used to find the minimum element in a binary search tree?
Postorder Traversal
Preorder Traversal
Level Order Traversal
Inorder Traversal
Which traversal method on a BST will visit the nodes in ascending order of their keys?
Pre-order Traversal
Level-order Traversal
In-order Traversal
Post-order Traversal
If a binary tree is considered balanced, what does it imply about its left and right subtrees?
They have the same number of nodes.
They are also balanced binary trees, and their heights differ by at most 1.
One subtree is always a mirror image of the other.
They have the same height.
What are the three main methods for traversing a binary tree?
Breadth-first, Depth-first, Level-order
Preorder, Inorder, Postorder
Linear, Binary, Exponential
Ascending, Descending, Random