
数据结构
文章平均质量分 62
kingofstorm7
研究生
展开
-
二叉树的遍历
中序遍历:void InorderTraversal( BinTree BT ){ if( BT ) { InorderTraversal( BT->Left ); /* 此处假设对BT结点的访问就是打印数据 */ printf("%d ", BT->Data); /* 假设数据为整型 */ InorderTraversal原创 2016-03-10 11:17:39 · 230 阅读 · 0 评论 -
二叉树的后续遍历
Leetcode145. Binary Tree Postorder Traversal 给定使用数组保存的二叉树,返回其后续遍历Given a binary tree, return the postorder traversal of its nodes' values.For example:Given binary tree {1,#,2,3},原创 2016-03-10 21:55:00 · 423 阅读 · 0 评论