Update the book based on the revised second edition (#1014)

* Revised the book

* Update the book with the second revised edition

* Revise base on the manuscript of the first edition
This commit is contained in:
Yudong Jin
2023-12-28 18:06:09 +08:00
committed by GitHub
parent 19dde675df
commit f68bbb0d59
261 changed files with 643 additions and 647 deletions
+1 -1
View File
@@ -29,7 +29,7 @@
设数组的长度为 $n$ ,冒泡排序的步骤如下图所示。
1. 首先,对 $n$ 个元素执行“冒泡”,**将数组的最大元素交换至正确位置**
1. 首先,对 $n$ 个元素执行“冒泡”,**将数组的最大元素交换至正确位置**
2. 接下来,对剩余 $n - 1$ 个元素执行“冒泡”,**将第二大元素交换至正确位置**。
3. 以此类推,经过 $n - 1$ 轮“冒泡”后,**前 $n - 1$ 大的元素都被交换至正确位置**。
4. 仅剩的一个元素必定是最小元素,无须排序,因此数组排序完成。