堆: 颗 -> 棵 (#343)

This commit is contained in:
方圆 2023-02-06 20:22:23 +08:00 committed by GitHub
parent 33e15da721
commit e7fdbe7ffb
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -247,7 +247,7 @@ comments: true
### 堆的存储与表示
在二叉树章节我们学过,「完全二叉树」非常适合使用「数组」来表示,而堆恰好是一完全二叉树,**因而我们采用「数组」来存储「堆」**。
在二叉树章节我们学过,「完全二叉树」非常适合使用「数组」来表示,而堆恰好是一完全二叉树,**因而我们采用「数组」来存储「堆」**。
**二叉树指针**。使用数组表示二叉树时,元素代表结点值,索引代表结点在二叉树中的位置,**而结点指针通过索引映射公式来实现**。