Removed redundant function from Binary Search Tree

This commit is contained in:
Luke Else 2022-04-17 21:48:38 +01:00
parent e5b0d1659b
commit 88a7a7577e

View File

@ -216,13 +216,5 @@ namespace C_.Datastructures.BinaryTree
} }
return node; return node;
} }
private void ReplaceChild(TreeNode<T> parent, TreeNode<T>? replacement){
if (parent.Value!.CompareTo(replacement!.Value) < 0)
{//Append to left side
parent.Left = replacement;
}//Append to right side
parent.Right = replacement;
}
} }
} }