I would like to contribute by adding the code implementation of Binary Search Tree (BST) using Python. The code will include functions for insertion, deletion, search, and traversal (in-order, pre-order, and post-order).
Problem Description:
We need to create a Binary Search Tree (BST) that can perform the following operations:
Insert a node into the BST.
Delete a node from the BST.
Search for a specific value in the BST.
Perform In-order, Pre-order, and Post-order traversal of the BST.
Input:
The first input will be a list of integers to be inserted into the BST.
After that, a number of queries will be given to perform operations such as insert, delete, or search.
Constraints:
Number of nodes, (N): (1 \leq N \leq 10^4)
Values of nodes: (-10^4 \leq value \leq 10^4)
Operations: Insert, Delete, Search
Output:
For each search operation, return "Found" if the value exists in the tree, otherwise return "Not Found".
For traversal operations, print the sequence of nodes.
I would like to contribute by adding the code implementation of Binary Search Tree (BST) using Python. The code will include functions for insertion, deletion, search, and traversal (in-order, pre-order, and post-order).
Problem Description:
We need to create a Binary Search Tree (BST) that can perform the following operations:
Input:
Constraints:
Output:
Sample Test Case:
Input:
Output:
Request:
I kindly request to assign this issue to me and add the hacktoberfest label.
Thank you!