码迷,mamicode.com
首页 >  
搜索关键字:substring    ( 3892个结果
Palindrome Partitioning
[leetcode]Given a string s, partition s such that every substring of the partition is a palindrome....
分类:其他好文   时间:2014-10-06 12:19:50    阅读次数:200
POJ 3693 Maximum repetition substring 后缀数组
论文里面的神题,题意大概是找出当前字符串中的一个子串,使得这个子串由N个字符串循环构成,输出N最大的子串,如果有多输出字典序最小的一个。解决方法感觉很犀利。。首先,对于循环节长度为L的子串,必然有这个子串会经过str[0],str[L],str[2*L]...中的任意两个字符,也就是必然会经过str...
分类:其他好文   时间:2014-10-04 23:57:07    阅读次数:319
字符串截取相关样例
例一:String.indexOf(String x):字符串x在字符串中第一次出现的下表索引,若不存在“x”,就返回-1String.substring(int beginindex):从字符串索引为beginindex開始截取,包含该索引String str = "陕西省|西安市|雁塔区";Sy...
分类:其他好文   时间:2014-10-04 14:46:26    阅读次数:185
LeetCode-Minimum Window Substring-最小窗口子串-滑动窗口算法(尺取法)
https://oj.leetcode.com/problems/minimum-window-substring/线性复杂度的限制下,考虑使用滑动窗口法。这个方法的思路就是维持一个窗口,窗口向右边界扩张以满足限制条件。窗口左边界收缩以尽量使其最小。注意这个题目可能是一个典型的滑动窗口方法的实现。外...
分类:Windows程序   时间:2014-10-04 02:29:05    阅读次数:317
【Leetcode】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...
分类:其他好文   时间:2014-10-04 01:10:45    阅读次数:200
大神刷题表
9月27日后缀数组:【wikioi3160】最长公共子串dp:NOIP2001统计单词个数后缀自动机:【spoj1812】Longest Common Substring II【wikioi3160】最长公共子串【spoj7258】Lexicographical Substring Search扫描...
分类:其他好文   时间:2014-10-03 15:17:24    阅读次数:1374
Longest Palindromic Substring
[leetcode]Given a string S, find the longest palindromic substring in S. You may assume that the maximum length of S is 1000, and there exists one unique longest palindromic substring....
分类:其他好文   时间:2014-10-02 13:30:42    阅读次数:217
Longest Substring Without Repeating Charactersdf
首先呢 可能会想到用一个windows去放这些东西.可能会想到hashtable去. 但是hashtable 无法用Index去查询.abcabcbb. hashtable: abc 当第二个a来的时候, 我们想bca 貌似不好实现.这种情况就很像LRU. 用 node连接,用hashta...
分类:其他好文   时间:2014-10-02 04:12:22    阅读次数:154
[Leetcode] Substring with Concatenation of All Words
You are given a string,S, and a list of words,L, that are all of the same length. Find all starting indices of substring(s) in S that is a concatenati...
分类:其他好文   时间:2014-10-01 17:00:11    阅读次数:170
[LeetCode] Longest Palindrome Substring 详细分析
Given a string S, find the longest palindromic substring in S. You may assume that the maximum length of S is 1000, and there exists one unique longest palindromic substring. 面DP题的考官都是神经病。。(吐...
分类:其他好文   时间:2014-10-01 13:15:31    阅读次数:242
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!