- #1
evinda
Gold Member
MHB
- 3,836
- 0
Hello! (Smile)
Suppose that we have the following AVL-tree and want to delete the node with the number [m]19[/m]:
View attachment 3883I thought that we replace the node [m]19[/m] with the node [m]52[/m] since it is the next node in the in-order traversal, and then the tree will be balnaced and so we don't have to make further notations.
So we will become the following tree:
View attachment 3884
Am I right?
Suppose that we have the following AVL-tree and want to delete the node with the number [m]19[/m]:
View attachment 3883I thought that we replace the node [m]19[/m] with the node [m]52[/m] since it is the next node in the in-order traversal, and then the tree will be balnaced and so we don't have to make further notations.
So we will become the following tree:
View attachment 3884
Am I right?