diff --git a/docs/assets/covers/chapter_array_and_linkedlist.jpg b/docs/assets/covers/chapter_array_and_linkedlist.jpg index ec380e100..c033f7c92 100644 Binary files a/docs/assets/covers/chapter_array_and_linkedlist.jpg and b/docs/assets/covers/chapter_array_and_linkedlist.jpg differ diff --git a/docs/assets/covers/chapter_backtracking.jpg b/docs/assets/covers/chapter_backtracking.jpg index 909f41be5..b5ee69c89 100644 Binary files a/docs/assets/covers/chapter_backtracking.jpg and b/docs/assets/covers/chapter_backtracking.jpg differ diff --git a/docs/assets/covers/chapter_dynamic_programming.jpg b/docs/assets/covers/chapter_dynamic_programming.jpg index 280cfc209..376a8900c 100644 Binary files a/docs/assets/covers/chapter_dynamic_programming.jpg and b/docs/assets/covers/chapter_dynamic_programming.jpg differ diff --git a/docs/assets/covers/chapter_greedy.jpg b/docs/assets/covers/chapter_greedy.jpg index 543940c9f..a64651745 100644 Binary files a/docs/assets/covers/chapter_greedy.jpg and b/docs/assets/covers/chapter_greedy.jpg differ diff --git a/docs/assets/covers/chapter_heap.jpg b/docs/assets/covers/chapter_heap.jpg index 13d0c73be..829bfbe11 100644 Binary files a/docs/assets/covers/chapter_heap.jpg and b/docs/assets/covers/chapter_heap.jpg differ diff --git a/docs/assets/covers/chapter_sorting.jpg b/docs/assets/covers/chapter_sorting.jpg index 678a2627f..3fbce55c9 100644 Binary files a/docs/assets/covers/chapter_sorting.jpg and b/docs/assets/covers/chapter_sorting.jpg differ diff --git a/docs/chapter_array_and_linkedlist/index.md b/docs/chapter_array_and_linkedlist/index.md index 20979edd4..1c0066391 100644 --- a/docs/chapter_array_and_linkedlist/index.md +++ b/docs/chapter_array_and_linkedlist/index.md @@ -5,3 +5,11 @@ { width="600" } + +!!! abstract + + 数组的砖块整齐排列,紧贴在一起。 + + 链表的砖块分散各处,连接的藤蔓自由地穿梭于砖缝之间。 + + 它们共同构成了数据结构的世界。 diff --git a/docs/chapter_backtracking/index.md b/docs/chapter_backtracking/index.md index ef432234c..83dc49da5 100644 --- a/docs/chapter_backtracking/index.md +++ b/docs/chapter_backtracking/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 我们如同迷宫中的探索者,在寻找出口的道路上可能会遇到困难。 + + 回溯的力量让我们能够重新开始,最终寻找到正确的道路。 diff --git a/docs/chapter_computational_complexity/index.md b/docs/chapter_computational_complexity/index.md index b042b9d75..e302bc562 100644 --- a/docs/chapter_computational_complexity/index.md +++ b/docs/chapter_computational_complexity/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 复杂度犹如浩瀚的算法宇宙中的指南针。 + + 它引导我们在时间与空间的维度上深入探索,寻找更优雅的解决方案。 diff --git a/docs/chapter_data_structure/index.md b/docs/chapter_data_structure/index.md index 96bafde96..2cfc9bcfe 100644 --- a/docs/chapter_data_structure/index.md +++ b/docs/chapter_data_structure/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 数据结构如同一副稳固而多样的框架。 + + 它为数据的有序组织提供了蓝图,使算法得以在此基础上生动起来。 diff --git a/docs/chapter_divide_and_conquer/index.md b/docs/chapter_divide_and_conquer/index.md index 8340ae9c7..679df58f7 100644 --- a/docs/chapter_divide_and_conquer/index.md +++ b/docs/chapter_divide_and_conquer/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 分治一次又一次地拆解难题,每一次的拆解都让问题变得更为简单。 + + 从简单做起,一切都不再复杂。 diff --git a/docs/chapter_dynamic_programming/index.md b/docs/chapter_dynamic_programming/index.md index 515097e59..c8a09a7af 100644 --- a/docs/chapter_dynamic_programming/index.md +++ b/docs/chapter_dynamic_programming/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 小溪汇入河流,江河汇入大海。 + + 动态规划将小问题的解汇集成大问题的答案,一步步引领我们走向解决问题的彼岸。 diff --git a/docs/chapter_graph/index.md b/docs/chapter_graph/index.md index d13458c0e..511e6e2ad 100644 --- a/docs/chapter_graph/index.md +++ b/docs/chapter_graph/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 在生命旅途中,我们就像是每个节点,被无数看不见的边相连。 + + 每一次的相识与相离,都在这张巨大的网络图中留下独特的印记。 diff --git a/docs/chapter_greedy/index.md b/docs/chapter_greedy/index.md index a6abfa6c2..d6307fed6 100644 --- a/docs/chapter_greedy/index.md +++ b/docs/chapter_greedy/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 向日葵朝着太阳转动,时刻都在追求自身成长的最大可能。 + + 这便是贪心的智慧,一种简单且高效的问题求解策略。 diff --git a/docs/chapter_hashing/index.md b/docs/chapter_hashing/index.md index 61dea6a7d..f0a567cd0 100644 --- a/docs/chapter_hashing/index.md +++ b/docs/chapter_hashing/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 在计算机世界中,散列表如同一位智能的图书管理员。 + + 他知道如何有序地组织数据,从而可以通过索书号快速找到目标书籍。 diff --git a/docs/chapter_heap/index.md b/docs/chapter_heap/index.md index 3ade71e3c..12fccd3fb 100644 --- a/docs/chapter_heap/index.md +++ b/docs/chapter_heap/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 堆就像是山川的峰峦,它们层叠起伏、形态各异。 + + 每一座山峰都有其高低之分,而最高的山峰总是最先映入眼帘。 diff --git a/docs/chapter_introduction/index.md b/docs/chapter_introduction/index.md index 3b317f1dc..510fcd05f 100644 --- a/docs/chapter_introduction/index.md +++ b/docs/chapter_introduction/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 一位少女翩翩起舞,与数据交织在一起,裙摆上飘扬着算法的旋律。 + + 她邀请你共舞,请紧跟她的步伐,踏入充满逻辑与美感的算法世界。 diff --git a/docs/chapter_preface/index.md b/docs/chapter_preface/index.md index 5a91e25d8..c7d59dba3 100644 --- a/docs/chapter_preface/index.md +++ b/docs/chapter_preface/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 这本书是为所有想要了解并掌握算法的读者编写的。 + + 无论你的背景如何,都可以在这里找到属于你的学习之旅。 diff --git a/docs/chapter_searching/index.md b/docs/chapter_searching/index.md index 3bc7b41f9..4939f1c55 100644 --- a/docs/chapter_searching/index.md +++ b/docs/chapter_searching/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 搜索是一场未知的冒险,我们或许需要走遍神秘空间的每个角落,又或许可以快速锁定目标。 + + 在这场寻觅之旅中,每一次探索都可能得到一个未曾料想的答案。 diff --git a/docs/chapter_sorting/index.md b/docs/chapter_sorting/index.md index 7b797c40e..fb753b1e3 100644 --- a/docs/chapter_sorting/index.md +++ b/docs/chapter_sorting/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 排序犹如一把将混乱变为秩序的魔法钥匙,使我们能以更高效的方式理解与处理数据。 + + 无论是简单的升序,还是复杂的分类排列,排序都向我们展示了数据的和谐美感。 diff --git a/docs/chapter_stack_and_queue/index.md b/docs/chapter_stack_and_queue/index.md index 1c845b758..e49dbba54 100644 --- a/docs/chapter_stack_and_queue/index.md +++ b/docs/chapter_stack_and_queue/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 栈如同叠猫猫,而队列就像猫猫排队。 + + 两者分别代表着先入后出和先入先出的逻辑关系。 diff --git a/docs/chapter_tree/binary_search_tree.md b/docs/chapter_tree/binary_search_tree.md index 6f8f09ff2..6aec5b01e 100755 --- a/docs/chapter_tree/binary_search_tree.md +++ b/docs/chapter_tree/binary_search_tree.md @@ -202,7 +202,9 @@  -当待删除节点的度为 $2$ 时,我们无法直接删除它,而需要使用一个节点替换该节点。由于要保持二叉搜索树“左 $<$ 根 $<$ 右”的性质,因此这个节点可以是右子树的最小节点或左子树的最大节点。假设我们选择右子树的最小节点(或者称为中序遍历的下个节点),则删除操作为: +当待删除节点的度为 $2$ 时,我们无法直接删除它,而需要使用一个节点替换该节点。由于要保持二叉搜索树“左 $<$ 根 $<$ 右”的性质,因此这个节点可以是右子树的最小节点或左子树的最大节点。 + +假设我们选择右子树的最小节点(即中序遍历的下一个节点),则删除操作为: 1. 找到待删除节点在“中序遍历序列”中的下一个节点,记为 `tmp` 。 2. 将 `tmp` 的值覆盖待删除节点的值,并在树中递归删除节点 `tmp` 。 diff --git a/docs/chapter_tree/index.md b/docs/chapter_tree/index.md index 37553c92b..d1cdebded 100644 --- a/docs/chapter_tree/index.md +++ b/docs/chapter_tree/index.md @@ -5,3 +5,9 @@ { width="600" } + +!!! abstract + + 参天大树充满生命力,其根深叶茂,分枝扶疏。 + + 它为我们展现了数据分治的生动形态。 diff --git a/docs/index.md b/docs/index.md index 879ae8a1b..bacf155ff 100644 --- a/docs/index.md +++ b/docs/index.md @@ -84,11 +84,11 @@ hide: