1. Add C++ codes for the chapter of

computational complexity, sorting, searching.
2. Corrected some mistakes.
3. Update README.
This commit is contained in:
Yudong Jin
2022-11-27 04:19:16 +08:00
parent f85ee36ce1
commit 431a0f6caf
37 changed files with 147 additions and 94 deletions

View File

@@ -5,8 +5,9 @@
package chapter_tree
import (
. "github.com/krahets/hello-algo/pkg"
"testing"
. "github.com/krahets/hello-algo/pkg"
)
func TestPreInPostOrderTraversal(t *testing.T) {
@@ -18,13 +19,13 @@ func TestPreInPostOrderTraversal(t *testing.T) {
// 前序遍历
nums := preOrder(root)
t.Log("前序遍历的结点打印序列 = ", nums)
t.Log("前序遍历的结点打印序列 =", nums)
// 中序遍历
nums = inOrder(root)
t.Log("中序遍历的结点打印序列 = ", nums)
t.Log("中序遍历的结点打印序列 =", nums)
// 后序遍历
nums = postOrder(root)
t.Log("后序遍历的结点打印序列 = ", nums)
t.Log("后序遍历的结点打印序列 =", nums)
}