class Solution {
public:
void dfs(vector<vector >&result, vectorcombination, vector&candidates, int kth, int k, int index2add){
// 当前正在确定组合中的第kth个数,将把候选集candidates中index2add索引位的值作为第kth个数加到组合中
combination.push_back(ca...
分类:
其他好文 时间:
2014-06-07 01:21:47
阅读次数:
220
【题目】
Given an array with n objects colored red, white or blue, sort them so that objects of the same color are adjacent, with the colors in the order red, white and blue.
Here, we will use the integers 0, 1, and 2 to represent the color red, white, and...
分类:
其他好文 时间:
2014-06-07 01:17:49
阅读次数:
269
【题目】
Given a string S and a string T, find the minimum window in S which will contain all the characters in T in complexity O(n).
For example,
S = "ADOBECODEBANC"
T = "ABC"
Minimum window is "BANC".
Note:
If there is no such window in S that covers ...
分类:
其他好文 时间:
2014-06-05 11:14:26
阅读次数:
255
题目:给定两个串s1和s2,对s1串,我们可以将其分割成两部分,这两部分都不为空,而被分割成的两部分,又可以递归的进行分割,直到不能进行分割为止,也就是只有一个字符的时候,就不在分割了。问s2是否由s1的这种分割表示中,某步分割成的两部分交换得到的。这种交换可以在不同的分割点进行多次。
/* s1
|__________p____________| ...
分类:
其他好文 时间:
2014-06-05 11:09:06
阅读次数:
207
【题目】
Given a string S and a string T, find the minimum window in S which will contain all the characters in T in complexity O(n).
For example,
S = "ADOBECODEBANC"
T = "ABC"
Minimum window is "BANC".
Note:
If there is no such window in S that covers ...
【题目】
Write an efficient algorithm that searches for a value in an m x n matrix. This matrix has the following properties:
Integers in each row are sorted from left to right.
The first integer of each row is greater than the last integer of the previous ...
分类:
其他好文 时间:
2014-06-05 08:28:43
阅读次数:
321
「Linux」本来指的仅仅是内核。5年之前大多都是这么认为的,但是最近不这么说了。最近一般都说「Linux」是个
OS,这里的OS,不仅仅是内核,而是指电脑的整体环境(除了内核,还包括一些外围的软件)。内核本来是作为硬件和各种应用软件之间的桥梁而存在的,只有内核的PC是无法使用的。因此,会将各式各样...
分类:
系统相关 时间:
2014-05-30 22:05:53
阅读次数:
391
中间件编辑中间件是一种独立的系统软件或服务程序,分布式应用软件借助这种软件在不同的技术之间共享资源。中间件位于客户机/
服务器的操作系统之上,管理计算机资源和网络通讯。是连接两个独立应用程序或独立系统的软件。相连接的系统,即使它们具有不同的接口,但通过中间件相互之间仍能交换信息。执行中间件的一个关键...
分类:
其他好文 时间:
2014-05-30 19:54:28
阅读次数:
541
经常在工作中或者在面试中会碰到这样的问题,比如我想要个布局右侧固定宽度 左侧自适应或者三列布局
左右固定 中间自适应的问题。 下面我们分别来学习下,当然我也是总结下而已,有如以下网站源码方法:一:右侧固定宽度
左侧自适应 第一种方法:左侧用margin-right,右侧float:right 就可以...
分类:
Web程序 时间:
2014-05-30 18:51:18
阅读次数:
417
Java 线程面试问题
在任何Java面试当中多线程和并发方面的问题都是必不可少的一部分。如果你想获得任何股票投资银行的前台资讯职位,那么你应该准备很多关于多线程的问题。在投资银行业务中多线程和并发是一个非常受欢迎的话题,特别是电子交易发展方面相关的。他们会问面试者很多令人混淆的Java线程问题。....
分类:
编程语言 时间:
2014-05-30 14:28:29
阅读次数:
247