AC自动机基础题。 1 #include 2 #include 3 #include 4 #include 5 #include 6 using namespace std; 7 8 #define MAXL 1000005 9 #define TRIEN 26 10...
分类:
其他好文 时间:
2014-07-07 17:12:08
阅读次数:
242
Problem Description:Given a binary tree and a sum, find all root-to-leaf paths where each path's sum equals the given sum.Solution: 递归。 1 public List>...
分类:
其他好文 时间:
2014-07-07 16:59:12
阅读次数:
169
extjs_07_combobox&tree&chart...
分类:
Web程序 时间:
2014-06-30 10:29:38
阅读次数:
259
【题目】
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 solution is trivial, could you do it iteratively?
【题意】
非递归实现后续遍...
分类:
其他好文 时间:
2014-06-30 10:10:10
阅读次数:
177
JAVA大数....
How Many Fibs?
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 3906 Accepted Submission(s): 1545
Problem Descri...
分类:
其他好文 时间:
2014-06-30 09:06:32
阅读次数:
160
【题目】
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 solution is trivial, could you do it iteratively?
【题意】
非递归返回先序遍历...
分类:
其他好文 时间:
2014-06-30 06:21:18
阅读次数:
334
rt 稳定婚姻匹配问题
The Stable Marriage Problem
Time Limit: 5000/1000 MS (Java/Others) Memory Limit: 65535/32768 K (Java/Others)
Total Submission(s): 438 Accepted Submission(s): 222
Proble...
分类:
其他好文 时间:
2014-06-30 00:35:18
阅读次数:
257
JAVA大数....
Integer Inquiry
Time Limit: 2000/1000 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 12042 Accepted Submission(s): 3037
Problem Descript...
分类:
其他好文 时间:
2014-06-30 00:18:48
阅读次数:
235
题目
Given a string s1, we may represent it as a binary tree by partitioning it to two non-empty substrings recursively.
Below is one possible representation of s1 = "great":
great
/...
分类:
其他好文 时间:
2014-06-29 23:16:19
阅读次数:
312
JAVA大数....
xx.stripTrailingZeros().toPlainString() 去末尾的0并不用科学计数法显示
Exponentiation
Time Limit: 1000/500 MS (Java/Others) Memory Limit: 65536/32768 K (Java/Others)
Total Submission(s): 6740...
分类:
其他好文 时间:
2014-06-29 20:31:02
阅读次数:
146