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

Commit db6d82d

Browse files
committed
Deploying to main from @ 0567d31 🚀
1 parent 409a8d0 commit db6d82d

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

‎book/linked_list.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -491,9 +491,9 @@ console.log(linkedList.count()); // output: 3
491491

492492
| 时间复杂度 | 链表 | 数组 |
493493
| :--------: | :----: | :----: |
494-
| 插入 | `O(n)` | `O(1)` |
495-
| 删除 | `O(n)` | `O(1)` |
496-
| 随机访问 | `O(1)` | `O(n)` |
494+
| 插入 | `O(1)` | `O(n)` |
495+
| 删除 | `O(1)` | `O(n)` |
496+
| 随机访问 | `O(n)` | `O(1)` |
497497

498498
不过数组和链表的性能对比,并不能局限于时间复杂度。在实际的软件开发中,不能仅仅利用复杂度分析就决定使用哪个数据结构来存储数据。
499499

0 commit comments

Comments
(0)

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