We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
先序遍历
栈S; p= root; while(p不空 || S不空){ while(p不空){ 访问p节点; p的右子树入S; p = p的左子树; } p = S栈顶弹出; }
后序遍历
栈S; p= root; while(p不空 || S不空){ while(p不空){ 访问p节点; p的左子树入S; p = p的右子树; } p = S栈顶弹出; } 结果序列逆序;
中序遍历
栈S; p= root; while(p不空 || S不空){ while(p不空){ p入S; p = p的左子树; } p = S栈顶弹出; 访问p; p = p的右子树; }
The text was updated successfully, but these errors were encountered:
No branches or pull requests
先序遍历
后序遍历
中序遍历
The text was updated successfully, but these errors were encountered: