when removing a node with two children, and if instructed to use the standard binary search tree node removal algorithm, should we replace it with the smallest node of the right subtree or the largest node of the left subtree?
1 Answer
Replace it with the largest node in the left subtree :)
Source that's as good as any: http://webdocs.cs.ualberta.ca/~holte/T26/del-from-bst.html