Given a binary tree, return thelevel ordertraversal of its nodes' values. (ie, from left to right, level by level).For example:Given binary tree{3,9,2...
分类:
其他好文 时间:
2014-12-03 21:12:08
阅读次数:
201
Given a binary tree and a sum, determine if the tree has a root-to-leaf path such that adding up all the values along the path equals the given sum.Fo...
分类:
其他好文 时间:
2014-12-03 21:12:00
阅读次数:
153
Given a binary tree, return thebottom-up level ordertraversal of its nodes' values. (ie, from left to right, level by level from leaf to root).For exa...
分类:
其他好文 时间:
2014-12-03 21:09:03
阅读次数:
119
createtable`sq`(
`id`int,
`user_id`varchar(45),
`userid_seq`varchar(45)
);
insertinto`sq`(`id`,`user_id`,`userid_seq`)values(‘1‘,‘zhang‘,NULL);
insertinto`sq`(`id`,`user_id`,`userid_seq`)values(‘2‘,‘wang‘,NULL);
insertinto`sq`(`id`,`user_id`,`userid_seq`..
分类:
数据库 时间:
2014-12-03 19:37:14
阅读次数:
253
Given a singly linked listL:L0→L1→…→Ln-1→Ln,reorder it to:L0→Ln→L1→Ln-1→L2→Ln-2→…You must do this in-place without altering the nodes' values.For exam...
分类:
其他好文 时间:
2014-12-03 13:49:04
阅读次数:
154
1、创建一个student,并且插入数据create table student(name varchar(12),age int)insert into student values('z1','1');insert into student values('z2','6');insert int...
分类:
数据库 时间:
2014-12-03 09:16:14
阅读次数:
211
问题描述:
Given n, how many structurally unique BST's (binary search trees) that store values 1...n?
For example,
Given n = 3, there are a total of 5 unique BST's.
1 3 3 2 1...
分类:
其他好文 时间:
2014-12-03 00:29:34
阅读次数:
136
今天在做一个程序时觉得TextView的背景色不好看,就想在xml文件中改变TextView的背景色。因为本人在 /res/values下放了一个colors.xml文件, 因此在xml文件中使用android:background="@colors/lightyellow"以图将TextView控...
分类:
移动开发 时间:
2014-12-03 00:23:47
阅读次数:
209
一、字符串格式化,在%左侧放置一个字符串,右侧放置希望格式化的值。>>> format = 'Hello,%s,%s enough for ya?'>>> values = ('world','Hot')>>> print format % valuesHello,world,Hot enough ...
分类:
编程语言 时间:
2014-12-02 22:14:17
阅读次数:
159
Binary Tree Inorder TraversalGiven a binary tree, return theinordertraversal of its nodes' values.For example:Given binary tree{1,#,2,3}, 1 \ ...
分类:
其他好文 时间:
2014-12-02 22:10:23
阅读次数:
138