Concept
How can we remove the Mal node while preserving the BST property?
Stephen Davies, Ph.D. Version 2.2.2 Through Discrete Mathematics A Cool Brisk Walk / Chapter 1
"Mal ” node from this tree, how would we do that? We can put the left-most node of Mal ’s right subtree (that would be River ) in Mal ’s place, and then make Simon (and everything under him) become Wash ’s left child. The result would look like this: River Jayne Inara Kaylee Zoe Simon Wash Take a moment and convince your- self that this Mal -less tree does in fact satisfy the BST property."
Related Ideas
- What makes a tree binary?Stephen Davies, Ph.D. Version 2.2.2 Through Discrete Mathematics A Cool Brisk Walk · Chapter 1
- What are the three ways to traverse a binary tree?Stephen Davies, Ph.D. Version 2.2.2 Through Discrete Mathematics A Cool Brisk Walk · Chapter 1
- Why is this graph not a tree?Stephen Davies, Ph.D. Version 2.2.2 Through Discrete Mathematics A Cool Brisk Walk · Chapter 1
- How is a tree traversed in pre-order?Stephen Davies, Ph.D. Version 2.2.2 Through Discrete Mathematics A Cool Brisk Walk · Chapter 1
- Why is this not a binary search tree?Stephen Davies, Ph.D. Version 2.2.2 Through Discrete Mathematics A Cool Brisk Walk · Chapter 1