Binary Search Tree
1. What is the worst-case time complexity of searching for a key in a binary search tree containing nodes?
2. What is the worst-case time complexity of deleting a key from a binary search tree containing nodes?
3. What is the time complexity of deleting a key from a balanced binary search tree containing nodes?
4. If all the queries in a BST-based application occur after all insertions and deletions are complete, which approach can be faster for answering the subsequent search queries?
5. What is the best-case time complexity of searching for a key in a BST when the key is stored at the root?
6. What is the space complexity of a recursive BST search in the worst case, considering the recursion stack?
7. If a BST has height , what is the time complexity of searching for a key in terms of ?
8. A balanced BST has height . What is the resulting time complexity of searching, inserting, or deleting a key when the required operation follows a root-to-leaf path?
9. Which factor primarily determines the time complexity of basic search, insertion, and deletion operations in a binary search tree?