题目:
Given a binary tree and a sum, find all root-to-leaf paths where each path's sum equals the given sum.
For example:
Given the below binary tree and sum = 22,
5
/...
分类:
编程语言 时间:
2015-07-21 12:54:55
阅读次数:
127
Given a string,find the length of the longest substring without repeating characters. Forexample, the longest substring without repeating letters for"abcabcbb" is "abc", which the length is 3. For"bbb...
分类:
其他好文 时间:
2015-07-21 12:54:53
阅读次数:
84
缩进Tab
取消缩进shift + Tab
查找 Ctrl + F
批量在数据首位添加代码
Ctrl + H
输入^,然后Find All,查找所有的行首 ,接下来批量首行添加
输入$,然后Find All,查找所有的行尾,接下来批量末行添加...
分类:
其他好文 时间:
2015-07-21 12:46:43
阅读次数:
117
题目:
Given a binary tree, find its minimum depth.
The minimum depth is the number of nodes along the shortest path from the root node down to the nearest leaf node.
题意:
给定一棵二叉树,返回它的最小高度。
最小高...
分类:
编程语言 时间:
2015-07-21 10:39:59
阅读次数:
132
写完备份后发现,数据需要定时删除;第一想法遍历文件,判断文件名,比对当前时间进行删除;然而这当然也是可以的;却又更加简便的方法;find /mnt/sqlBac/ -type f -mtime +15 -exec rm -f '{} \;'find /mnt/sqlBac/ -type f -mti...
分类:
系统相关 时间:
2015-07-21 10:13:59
阅读次数:
140
【016-3 Sum Closest(最接近的三个数的和)】【LeetCode-面试算法经典-Java实现】【所有题目目录索引】原题 Given an array S of n integers, find three integers in S such that the sum is closest to a given number, target. Return the sum of th...
分类:
编程语言 时间:
2015-07-21 09:10:14
阅读次数:
151
【013-3 Sum(三个数的和)】【LeetCode-面试算法经典-Java实现】【所有题目目录索引】原题 Given an array S of n integers, are there elements a, b, c in S such that a + b + c = 0? Find all unique triplets in the array which gives the su...
分类:
编程语言 时间:
2015-07-21 09:10:13
阅读次数:
181
Find a multipleTime Limit: 1000MSMemory Limit: 65536KTotal Submissions: 6651Accepted: 2910Special JudgeDescriptionThe input contains N natural (i.e. p...
分类:
其他好文 时间:
2015-07-21 09:04:44
阅读次数:
140
题目描述
链接地址
解法
算法解释题目描述Given an array of integers, the majority number is the number that occurs more than half of the size of the array. Find it..ExampleGiven [1, 1, 1, 1, 2, 2, 2], return 1ChallengeO(n...
分类:
其他好文 时间:
2015-07-21 01:36:33
阅读次数:
186
题目:
Given s1, s2, s3, find whether s3 is formed by the interleaving of s1 and s2.
For example,
Given:
s1 = "aabcc",
s2 = "dbbca",
When s3 = "aadbbcbcac", return true.
When s3 = "aadbbba...
分类:
编程语言 时间:
2015-07-20 23:52:55
阅读次数:
282