2014年8月25日

二元查找树转变成排序的双向链表

摘要: 转自http://zhedahht.blog.163.com/blog/static/254111742007127104759245/题目:输入一棵二元查找树,将该二元查找树转换成一个排序的双向链表。要求不能创建任何新的结点,只调整指针的指向。 比如将二元查找树 10 / \ 6 14 / \ ... 阅读全文

posted @ 2014-08-25 11:29 theCambrian.cpp 阅读(221) 评论(0) 推荐(0) 编辑

求二叉树中和为给定值的所有路径

摘要: 转自:http://blog.csdn.net/lalor/article/details/7614381问题定义: You are given a binary tree in which each node contains a value. Design an algorithm to ... 阅读全文

posted @ 2014-08-25 09:57 theCambrian.cpp 阅读(281) 评论(0) 推荐(0) 编辑

导航