Given a set of candidate numbers (C) and a target number (T), find all unique combinations in C where
the candidate numbers sums to T.
The same repeated number may be chosen from C unlimited numb...
分类:
其他好文 时间:
2015-07-25 20:00:54
阅读次数:
138
Lowest Common Ancestor of a Binary Tree
Given a binary tree, find the lowest common ancestor (LCA) of two given nodes in the tree.
According to the definition of LCA on Wikipedia: “The lowest...
分类:
其他好文 时间:
2015-07-25 20:00:08
阅读次数:
146
题目传送门 1 /* 2 题意:给出一个数,问是否有ai + bj + ck == x 3 二分查找:首先计算sum[l] = a[i] + b[j],对于q,枚举ck,查找是否有sum + ck == x 4 */ 5 #include 6 #include 7 #incl...
分类:
其他好文 时间:
2015-07-25 19:49:45
阅读次数:
101
1. 正则表达式(1) 正则表达式用来在文件中匹配符合条件的字符串,正则是包含匹配。grep、awk、sed等命令可以支持正则表达式;通配符用来匹配符合条件的文件名,通配符是完全匹配。ls、find、cp这些命令不支持正则表达式,所以只能使用shell自己的通配符来进行匹配了。(2) 基础正则表达式...
分类:
系统相关 时间:
2015-07-25 18:23:17
阅读次数:
170
https://leetcode.com/problems/kth-largest-element-in-an-array/ Find the kth largest element in an unsorted array. Note that it is the kth largest elem...
分类:
其他好文 时间:
2015-07-25 18:15:37
阅读次数:
100
jQuery使用的是sizzle这个选择器引擎,这个引擎以其高速著称,其实现十分精妙但是也足够复杂,下面现简单分析一下相关的代码。在jQuery的部分API接口是直接引用了Sizzle的方法,这些接口如下:1 jQuery.find = Sizzle;2 jQuery.expr = Sizzle.....
分类:
Web程序 时间:
2015-07-25 16:40:04
阅读次数:
143
Given an arraySofnintegers, find three integers inSsuch that the sum is closest to a given number, target. Return the sum of the three integers. You m...
分类:
其他好文 时间:
2015-07-25 16:36:25
阅读次数:
101
1. 测试文档:# test_input.txtWelcome to World Wide Spam. Inc.These are the corporate web pages of *World Wide Spam*, Inc. We hope you find your stay enjoya...
分类:
编程语言 时间:
2015-07-25 16:34:03
阅读次数:
167
Find a wayTime Limit: 3000/1000 MS (Java/Others)Memory Limit: 32768/32768 K (Java/Others)Total Submission(s): 6221Accepted Submission(s): 2070Problem ...
分类:
其他好文 时间:
2015-07-25 16:32:16
阅读次数:
147
更多的是,有关于选择器的内容。背景:查找某控件中所有的input元素,代码如下:1 $("#div1").find("input").each(function () {2 alert($(this).attr("value"));3 });上...
分类:
Web程序 时间:
2015-07-25 13:45:15
阅读次数:
192