码迷,mamicode.com
首页 >  
搜索关键字:longest substring    ( 5540个结果
LeetCode题解 || Longest Substring Without Repeating Characters (O(n)算法)问题
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
leetcode------Palindrome Partitioning
标题: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
(转)JS截取字符串substr 和 substring方法的区别
网址来源:http://www.cnblogs.com/hema/archive/2009/10/21/1587560.htmlsubstr方法返回一个从指定位置开始的指定长度的子字符串。stringvar.substr(start[,length])参数stringvar必选项。要提取子字符串的字...
分类:Web程序   时间:2015-03-16 14:29:28    阅读次数:133
[LeetCode] Minimum Window Substring 最小窗口子串
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...
分类:Windows程序   时间:2015-03-16 07:36:20    阅读次数:311
Longest Common Prefix
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
Longest Substring Without Repeating Characters
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
Leetcode-3 Longest Substring Without Repeating Characters
?? 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
LeetCode -- Longest Valid Parentheses(Dynamic Programming)
题目地址: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
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
SPOJ Problem 1437:Longest path in a tree
求树的最长链,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
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!