What is binary search tree and explain its time complexity?
Answer / Sunil Kumar Rajpal
A Binary Search Tree (BST) is a binary tree where each node has at most two children, and the left subtree contains only nodes with keys less than the parent node, while the right subtree contains only nodes with keys greater than the parent node. The time complexity for basic operations such as search, insert, and delete in a balanced BST is O(log n).
| Is This Answer Correct ? | 0 Yes | 0 No |
Write a code for dynamic allocation of array.
What is array and string?
Mention some drawbacks of the linked list.
Two linked lists are given, find out the sum of them without altering the linked list?
Which is faster hashmap or linkedhashmap?
List some applications of tree-data structure?
Is hashmap get thread safe?
What is selection in an algorithm?
How is any data structure application is classified among files?
Describe the merge sort principle and what will be its time complexity?
what is Singly Linked list?
Does treemap sort automatically?