码迷,mamicode.com
首页 >  
搜索关键字:longest substring    ( 5540个结果
第四章 语言模块
1.字符串的扩展与修复语言脚本都对字符串特别关注,有关的方法特别多,这些方法有三大类:第一类:与标签无关的实现:charAt,charCodeAt,concat,lastIndexOf,localeCompare,match,replace,slice,split,substr,substring,...
分类:编程语言   时间:2015-06-08 01:02:19    阅读次数:162
POJ3415:Common Substrings(后缀数组+单调栈)
Description A substring of a string T is defined as: T(i, k)=TiTi+1...Ti+k-1, 1≤i≤i+k-1≤|T|. Given two strings A, B and one integer K, we define S, a set of triples (i, j, k): S = {(i, j, ...
分类:编程语言   时间:2015-06-07 23:41:18    阅读次数:391
[LeetCode] Longest Substring Without Repeating Characters
Well, there many ways to solve this problem. Let's first look at a naive solution.The basic idea is simple. Starting from the first character of the s...
分类:其他好文   时间:2015-06-07 21:31:03    阅读次数:128
Project Euler:Problem 50 Consecutive prime sum
The prime 41, can be written as the sum of six consecutive primes: 41 = 2 + 3 + 5 + 7 + 11 + 13 This is the longest sum of consecutive primes that adds to a prime below one-hundred. The longest s...
分类:其他好文   时间:2015-06-07 17:35:13    阅读次数:129
LeetCode【8】. String to Integer (atoi) --java实现
String to Integer (atoi) Implement atoi to convert a string to an integer. Hint: Carefully consider all possible input cases. If you want a challenge, please do not see below and ask you...
分类:编程语言   时间:2015-06-07 06:15:52    阅读次数:181
【leetcode】Palindrome Partitioning
Given a string s, partition s such that every substring of the partition is a palindrome.Return all possible palindrome partitioning of s.For example,...
分类:其他好文   时间:2015-06-06 21:57:41    阅读次数:122
[Guava源码阅读笔记]-Basic Utilities篇-1
写该系列文章的目的是记录Guava源码中个人感觉不错且值得借鉴的内容。 一、MoreObjects类 //MoreObjects.ToStringHelper类的toString()方法:对于字符串拼接的写法蛮不错的,此前本人一直用比较挫的方式:不管三七二一,先拼接然后再subString() @Override public String toString() { /...
分类:其他好文   时间:2015-06-06 20:46:37    阅读次数:311
LeetCode3 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 for "abcabcbb" is "abc", which the length is...
分类:其他好文   时间:2015-06-06 14:57:54    阅读次数:120
LeetCode 14:Longest Common Prefix
Write a function to find the longest common prefix string amongst an array of strings.求最长公共前缀:以第一个字符串为模板比较之后的字符串即可。 1 public class Solution { 2 pu...
分类:其他好文   时间:2015-06-06 10:33:58    阅读次数:102
LeetCode 3:LongestSubString
Given a string, find the length of the longest substring without repeating characters. For example, the longest substring without repeating letters fo...
分类:其他好文   时间:2015-06-06 10:25:13    阅读次数:115
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!