Binary Tree

 16th March 2021 at 11:39am

二叉树。

树的遍历

Depth First Traversals:

  • Inorder (Left, Root, Right) : 4 2 5 1 3
  • Preorder (Root, Left, Right) : 1 2 4 5 3
  • Postorder (Left, Right, Root) : 4 5 2 3 1

Breadth First or Level Order Traversal: 1 2 3 4 5

算法实现

TOC