<jupyter_start><jupyter_text>Practicing Adding Deletion You have just added the abiliy to insert and search on the tree lets take it one step farther by having you add the ability to delete of the tree as well.   Try it<jupyter_code>class Node(object):
    def __init__(self, value):
        self.value = value
        self.left = None
        self.right = None

class BST(object):
    def __init__(self, root):
        self.root = Node(root)

    def insert(self, new_val):
        # Use your old insert function
        pass

    def search(self, find_val):
        # Use your old search function
        return False
    
    def delete(self, del_val):
        # TODO: Implement a delete function
        pass<jupyter_output><empty_output><jupyter_text>Test Cases<jupyter_code># Set up tree
tree = BST(4)

# Insert elements
tree.insert(2)
tree.insert(1)
tree.insert(3)
tree.insert(5)

# Check search
print ("Pass" if tree.search(4) else "Fail")
print ("Pass" if not tree.search(6) else "Fail")

# Delete elements
tree.delete(5)

# Should be False
print ("Pass" if not tree.search(5) else "Fail")<jupyter_output><empty_output>
{'fraction_non_alphanumeric': 0.09663120567375887, 'fraction_numerical': 0.007978723404255319, 'mean_word_length': 3.3256704980842913, 'pattern_counts': {'":': 0, '<': 9, '<?xml version=': 0, '>': 9, 'https://': 0, 'lorem ipsum': 0, 'www.': 0, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 0, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'chain_length': '2', 'dir': 'jupyter-structured-clean-dedup', 'id': '505435', 'license': 'MIT', 'n_tokens_mistral': 366, 'n_tokens_neox': 361, 'n_words': 122, 'path': 'trees/Practice Adding Deletion.ipynb', 'repo_name': 'PRkudupu/Algo-python', 'size': '1128'}