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
Which traversal technique is typically used to find the minimum element in a binary search tree?
Inorder Traversal
Postorder Traversal
Level Order Traversal
Preorder Traversal
Which of the following is a valid approach for deleting a node with two children in a binary tree?
Replace the node with its inorder successor
Swap the node with its parent
None of the above
Simply remove the node
To find the maximum element in a binary tree that is not a binary search tree, which traversal method is generally most suitable?
Any traversal method can be used
The path from the root to any node in a binary tree is always:
Non-unique
Circular
Disconnected
Unique
A complete binary tree with 'n' nodes will always have a height of:
n
n/2
floor(log2(n)) + 1
log2(n)
Which traversal method on a BST will visit the nodes in ascending order of their keys?
Level-order Traversal
In-order Traversal
Post-order Traversal
Pre-order Traversal
What is the worst-case time complexity for searching for a node in a balanced binary tree?
O(1)
O(log n)
O(n^2)
O(n)
In a binary tree, what is the depth of a node?
The number of nodes at the same level as the node.
The height of the subtree rooted at that node.
The length of the path from the root to that node.
The number of children the node has.
Nodes that share the same parent are called:
Cousins
Ancestors
Siblings
Descendants