https://oj.leetcode.com/problems/binary-tree-preorder-traversal/Given a binary tree, return thepreordertraversal of its nodes' values.For example:Give...
分类:
其他好文 时间:
2015-01-15 21:33:47
阅读次数:
138
本文是在学习中的总结,欢迎转载但请注明出处:http://blog.csdn.net/pistolove/article/details/42744919
Given a binary tree, flatten it to a linked list in-place.
For example,
Given
1
/ \...
分类:
其他好文 时间:
2015-01-15 20:23:45
阅读次数:
158
问题描述:
Two elements of a binary search tree (BST) are swapped by mistake.
Recover the tree without changing its structure.
Note:
A solution using O(n) space is pretty straight forward. Could you...
分类:
其他好文 时间:
2015-01-15 20:18:55
阅读次数:
137
1.在Apache官网下载Apache最新poi版本:poi-bin-3.11-20141221.zip,解压;这里要注意是在binary distribution 下载,binary distribution是jar包,source distribution是包含源文件的,可以打开java代码2....
分类:
编程语言 时间:
2015-01-15 17:33:18
阅读次数:
184
Binary Search Tree IteratorImplement an iterator over a binary search tree (BST). Your iterator will be initialized with the root node of a BST.Callin...
分类:
其他好文 时间:
2015-01-15 15:48:15
阅读次数:
135
Given a binary tree, return the preorder traversal of its nodes' values.
For example:
Given binary tree {1,#,2,3},
1
2
/
3
return [1,2,3].
Note: Recursive soluti...
分类:
其他好文 时间:
2015-01-15 13:04:35
阅读次数:
160
Given a binary tree, return the postorder traversal of its nodes' values.
For example:
Given binary tree {1,#,2,3},
1
2
/
3
return [3,2,1].
Note: Recursive solut...
分类:
其他好文 时间:
2015-01-15 13:00:56
阅读次数:
141
/** class for nodes used in a binary tree */package dataStructures;public class BinaryTreeNode { // package visible data members Object element;...
分类:
其他好文 时间:
2015-01-15 10:47:12
阅读次数:
206
二叉树的前序,中序,后序,层次遍历/** binary tree traversal methods */package dataStructures;public class BinaryTreeTraversal { /** visit method that prints the ele...
分类:
其他好文 时间:
2015-01-15 10:37:52
阅读次数:
230
Given a binary tree containing digits from 0-9 only, each root-to-leaf path could represent
a number.
An example is the root-to-leaf path 1->2->3 which represents the number 123.
Find the tota...
分类:
其他好文 时间:
2015-01-15 09:26:49
阅读次数:
117