problem:
Given a string, find the length of the longest substring without repeating characters. For example, the longest substring without repeating letters for "abcabcbb" is "abc", which the length...
分类:
编程语言 时间:
2015-03-16 16:25:54
阅读次数:
155
标题:Palindrome Partitioning通过率:26.3%难度:中等Given a strings, partitionssuch that every substring of the partition is a palindrome.Return all possible pali...
分类:
其他好文 时间:
2015-03-16 16:07:04
阅读次数:
121
网址来源:http://www.cnblogs.com/hema/archive/2009/10/21/1587560.htmlsubstr方法返回一个从指定位置开始的指定长度的子字符串。stringvar.substr(start[,length])参数stringvar必选项。要提取子字符串的字...
分类:
Web程序 时间:
2015-03-16 14:29:28
阅读次数:
133
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...
Longest Common Prefix问题:Write a function to find the longest common prefix string amongst an array of strings.思路: 简单的string运算我的代码:public class Soluti....
分类:
其他好文 时间:
2015-03-15 18:11:46
阅读次数:
86
Given a string, find the length of the longest substring without repeating characters. For example, the longest substring without repeating letters fo...
分类:
其他好文 时间:
2015-03-15 13:43:07
阅读次数:
134
??
1.3- Longest Substring Without Repeating Characters
Given a string,find the length of the longest substring without repeating characters. Forexample, the longest substring without repeating l...
分类:
其他好文 时间:
2015-03-14 18:40:32
阅读次数:
123
题目地址:https://leetcode.com/problems/longest-valid-parentheses/Given a string containing just the characters ‘(’ and ‘)’, find the length of the longest valid (well-formed) parentheses substring.
For “(...
分类:
其他好文 时间:
2015-03-14 16:55:18
阅读次数:
188
Palindrome Partitioning问题:Given a strings, partitionssuch that every substring of the partition is a palindrome.Return all possible palindrome partiti...
分类:
其他好文 时间:
2015-03-14 13:41:00
阅读次数:
108
求树的最长链,BFS和DFS都可以,时间复杂度O(n)#include#includeint tot,vt[20005],nxt[20005],a[20005];bool vis[10005];int n,i,j,xx,yy,s,ma,r;void search(int x,int dep){ .....
分类:
其他好文 时间:
2015-03-14 10:58:28
阅读次数:
207