mirror of
https://github.com/krahets/hello-algo.git
synced 2026-04-13 10:39:54 +08:00
deploy
This commit is contained in:
@@ -3646,7 +3646,7 @@
|
||||
|
||||
|
||||
<h1 id="75-avl">7.5 AVL 树 *<a class="headerlink" href="#75-avl" title="Permanent link">¶</a></h1>
|
||||
<p>在二叉搜索树章节中,我们提到了在多次插入和删除操作后,二叉搜索树可能退化为链表。这种情况下,所有操作的时间复杂度将从 <span class="arithmatex">\(O(\log n)\)</span> 恶化为 <span class="arithmatex">\(O(n)\)</span>。</p>
|
||||
<p>在二叉搜索树章节中,我们提到了在多次插入和删除操作后,二叉搜索树可能退化为链表。这种情况下,所有操作的时间复杂度将从 <span class="arithmatex">\(O(\log n)\)</span> 恶化为 <span class="arithmatex">\(O(n)\)</span> 。</p>
|
||||
<p>如图 7-24 所示,经过两次删除节点操作,这个二叉搜索树便会退化为链表。</p>
|
||||
<p><img alt="AVL 树在删除节点后发生退化" src="../avl_tree.assets/avltree_degradation_from_removing_node.png" /></p>
|
||||
<p align="center"> 图 7-24 AVL 树在删除节点后发生退化 </p>
|
||||
|
||||
Reference in New Issue
Block a user