py-bst
py-bst copied to clipboard
Bug in _delete_leaf_parent in AVLTree
When deleting the root (node.key == self.Root.key), the code doesn't set the new root's parent to None, which leads to unexpected behaviors. This is easy to fix by setting self.Root.parent = None after the update.