mirror of
https://github.com/krahets/hello-algo.git
synced 2026-07-20 02:26:11 +00:00
Feature/array representation of tree swift (#649)
* refactor: encode & decode Tree * style: build warning * feat: add Swift codes for array_representation_of_tree article
This commit is contained in:
@@ -79,7 +79,7 @@ public enum PrintUtil {
|
||||
print("堆的数组表示:", terminator: "")
|
||||
print(queue)
|
||||
print("堆的树状表示:")
|
||||
let root = TreeNode.listToTree(list: queue)
|
||||
let root = TreeNode.listToTree(arr: queue)
|
||||
printTree(root: root)
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user