h*****u 发帖数: 109 | 1 多位网友发过了,比如ultrabo,小节一下考点
A
/
B C
共六种排列 (要求): inorder, preorder, postorder, inorder right first (CAB),
preorder right first (ACB), postorder right first (CBA)
实现技术:recursive, iterative with one stack, iterative with two stacks,
iterative with parent pointer but no stacks, iterative with threaded binary
trees, Morris traversal (dynamic threaded tree)
做一个表,行是六种要求,列是各种技术,一共多少啊?还有没想到的吧。
Morris traversal codes: http://www.cnblogs.com/AnnieKim/archive/2013/06/15/MorrisTraversal.html | b****f 发帖数: 138 | | k*****o 发帖数: 43 | |
|