Prepare 1.1.0 release (#1274)

* Update bucket_sort.c

* Fix the comments in quick_sort.c

* Update the announce badge

* Sync zh and zh-hant versions

* Update contributors list.

* Sync zh and zh-hant versions.

* Sync zh and zh-hant versions.

* Update the contributors list

* Update the version number
This commit is contained in:
Yudong Jin
2024-04-14 20:46:20 +08:00
committed by GitHub
parent 16942dfe32
commit d484b08c15
43 changed files with 471 additions and 115 deletions
@@ -19,7 +19,7 @@ fun levelOrder(root: TreeNode?): MutableList<Int> {
val list = mutableListOf<Int>()
while (queue.isNotEmpty()) {
val node = queue.poll() // 隊列出隊
list.add(node?._val!!) // 儲存節點值
list.add(node?._val!!) // 儲存節點值
if (node.left != null)
queue.offer(node.left) // 左子節點入列
if (node.right != null)
@@ -31,7 +31,7 @@ fun levelOrder(root: TreeNode?): MutableList<Int> {
/* Driver Code */
fun main() {
/* 初始化二元樹 */
// 這裡藉助了一個從列直接生成二元樹的函式
// 這裡藉助了一個從列直接生成二元樹的函式
val root = TreeNode.listToTree(mutableListOf(1, 2, 3, 4, 5, 6, 7))
println("\n初始化二元樹\n")
printTree(root)