题目: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 = "ADOBE....
分类:
编程语言 时间:
2014-07-28 14:42:23
阅读次数:
264
Setup SlackHold SlackRecovery&RemovalRecovery: The minimum time an asynchronous signal must be stable BEFORE clock edgeRemoval : The minimum time an a...
分类:
其他好文 时间:
2014-07-27 23:08:50
阅读次数:
443
//============================================================================// Name : B.cpp// Author : L_Ecry// Version :// Copyrigh...
分类:
其他好文 时间:
2014-07-27 22:20:39
阅读次数:
167
Description
Given a connected undirected graph, tell if its minimum spanning tree is unique.
Definition 1 (Spanning Tree): Consider a connected, undirected graph G = (V, E). A spanning tree of...
分类:
其他好文 时间:
2014-07-26 17:19:22
阅读次数:
401
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="ADOBECODEBA...
查看当前分区状态:[root@localhost~]#fdisk-culDisk/dev/sda:21.5GB,21474836480bytes255heads,63sectors/track,2610cylinders,total41943040sectorsUnits=sectorsof1*512=512bytesSectorsize(logical/physical):512bytes/512bytesI/Osize(minimum/optimal):512bytes/512bytes..
分类:
其他好文 时间:
2014-07-26 03:13:57
阅读次数:
286
Given a m x n grid filled with non-negative numbers, find a path from top left to bottom right which minimizes the sum of all numbers along its path.N...
分类:
其他好文 时间:
2014-07-26 01:42:16
阅读次数:
263
Description
There is a sequence of integers. Your task is to find the longest subsequence that satisfies the following condition: the difference between the maximum element and the minimum element ...
分类:
其他好文 时间:
2014-07-25 11:06:41
阅读次数:
242
今天温习树状数组,果然忘记了好多,树状数组求逆序数,值得注意这道题所有的数都是0-n-1的,所以在求最小的时候不用每个数顺序在计算一遍,我已开始就是把每个顺序又计算了一遍,果断超时了。第i个数拿到后面去,逆序数会减少a[i]-1,同时会增加n-a[i]
#include
#include
using namespace std;
int a[5005],tree[5005],n;
int low...
分类:
其他好文 时间:
2014-07-23 21:00:35
阅读次数:
186
Description:Given a strings, partitionssuch that every substring of the partition is a palindrome.Return the minimum cuts needed for a palindrome part...
分类:
其他好文 时间:
2014-07-23 20:34:35
阅读次数:
235