Binary Tree TraversalsTime Limit: 1000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 3340Accepted Submission(s): ...
分类:
其他好文 时间:
2015-07-06 11:36:29
阅读次数:
72
一、注册表基本知识
1) 结构
键->项->子项->值项(名称、类型、数据)
REG_SZ 字符串
REG_BINARY 二进制
REG_DWORD 双字
2) 组成
1.HKEY_CLASSES_ROOT 定义了系统中所有文件类型标识和基本操作标识
该主键包含文件扩展名和应用程序...
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...
分类:
编程语言 时间:
2015-07-06 06:37:44
阅读次数:
125
Add Binary
Total Accepted: 46815
Total Submissions: 189215
My Submissions
Given two binary strings, return their sum (also a binary string).
For example,
a =...
分类:
其他好文 时间:
2015-07-05 22:35:34
阅读次数:
228
解法一:递归1 int maxDepth(TreeNode* root)2 {3 if (root == NULL)4 return 0;5 6 int max_left_Depth = maxDepth(root->left);7 int max_right...
分类:
其他好文 时间:
2015-07-05 18:31:24
阅读次数:
101
解法一:From top to bottom 1 int treeHeight(TreeNode *T) 2 { 3 if (T == NULL) 4 return 0; 5 6 return max(treeHeight(T->left), treeHei...
分类:
其他好文 时间:
2015-07-05 18:23:33
阅读次数:
82
Given a binary search tree, write a function kthSmallestto find the kth
smallest element in it.
Note:
You may assume k is always valid, 1 ≤ k ≤ BST's total elements.
解题思路:
求BST(二叉排序树)中第k小的数...
分类:
其他好文 时间:
2015-07-05 16:53:00
阅读次数:
150
题目描述: We are all familiar with pre-order, in-order and post-order traversals of binary trees. A common problem in data structure classes is to find th...
分类:
其他好文 时间:
2015-07-05 16:26:26
阅读次数:
105
方法1:递归。int minDepth(TreeNode* root) { if (root == NULL) return 0; if (root->left == NULL) { return minDepth(root->right) + 1; }...
分类:
其他好文 时间:
2015-07-04 23:21:39
阅读次数:
143
今天特地查了一下SQL Server下的校检函数有哪些。原本我只是在工作中用过一个CHECKSUM,今天特地学习了一下才发现原来还有其他的校检函数。这里找到了别人对于SQL SERVER下这几个校检函数的学习总结,借此机会学习下别人的学习成果http://bbs.51cto.com/thread-1...
分类:
数据库 时间:
2015-07-04 19:38:21
阅读次数:
209