Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

[pull] main from itcharge:main #178

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
pull merged 6 commits into AlgorithmAndLeetCode:main from itcharge:main
May 10, 2024
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
更新 02.02.01 堆栈基础知识 相关图片、图片标题
  • Loading branch information
itcharge committed May 9, 2024
commit 6763e99d5bb3757e55c7b84bd1738d88c7ce9ffe
6 changes: 3 additions & 3 deletions Contents/03.Stack/01.Stack-Basic/01.Stack-Basic.md
View file Open in desktop
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@
- 栈的插入操作又称为「入栈」或者「进栈」。
- 栈的删除操作又称为「出栈」或者「退栈」。

![](https://qcdn.itcharge.cn/images/20211202095938.png)
![堆栈结构](https://qcdn.itcharge.cn/images/202405092243204.png)

简单来说,栈是一种 **「后进先出(Last In First Out)」** 的线性表,简称为 **「LIFO 结构」**。

Expand Down Expand Up @@ -57,7 +57,7 @@

#### 2.2.1 堆栈的顺序存储基本描述

![](https://qcdn.itcharge.cn/images/20211202101936.png)
![堆栈的顺序存储](https://qcdn.itcharge.cn/images/202405092243306.png)

我们约定 $self.top$ 指向栈顶元素所在位置。

Expand Down Expand Up @@ -114,7 +114,7 @@ class Stack:

堆栈的顺序存储结构保留着顺序存储分配空间的固有缺陷,即在栈满或者其他需要重新调整存储空间时需要移动大量元素。为此,堆栈可以采用链式存储方式来实现。在 Python 中我们通过构造链表节点 $Node$ 的方式来实现。这种采用链式存储结构的堆栈也被称为 **「链式栈」**。

![](https://qcdn.itcharge.cn/images/20211202103327.png)
![堆栈的链式存储](https://qcdn.itcharge.cn/images/202405092243367.png)

#### 2.3.1 堆栈的链式存储基本描述

Expand Down

AltStyle によって変換されたページ (->オリジナル) /