紅黑樹學習筆記(3)-刪除操作

1、設刪除的節點爲$z$,另外定義節點$x,y$如下: $y=\left\{\begin{matrix}z & z的左孩子或右孩子爲空節點\\ Successor(z) & otherwise\end{matrix}\right.$ $x=\left\{\begin{matrix}y.left & y的左孩子不爲空\\ y.right & otherwise\end{matrix}\right.$
相關文章
相關標籤/搜索