码迷,mamicode.com
首页 >  
搜索关键字:longest consecutive    ( 3017个结果
565. Array Nesting
A zero-indexed array A of length N contains all integers from 0 to N-1. Find and return the longest length of set S, where S[i] = {A[i], A[A[i]], A[A[ ...
分类:其他好文   时间:2017-12-23 14:10:55    阅读次数:188
LeetCode #3 Longest Substring Without Repeating Characters
Description Given a string, find the length of the longest substring without repeating characters. 题意 给定一个字符串,求出不带重复字符的最长子串的长度。 Example Given "abcabcb ...
分类:其他好文   时间:2017-12-22 19:46:26    阅读次数:93
LeetCode:14. Longest Commen Prefix(Easy)
1. 原题链接 https://leetcode.com/problems/longest-common-prefix/description/ 2. 题目要求 给定一个字符串数组,让你求出该数组中所有字符串的最大公共前缀。例如{"qqwwee", "qqww", "qqfds"}的最大公共前缀为" ...
分类:其他好文   时间:2017-12-20 13:33:20    阅读次数:173
回文串最大长度
1)lettcode题目: Given a string s, find the longest palindromic substring in s. You may assume that the maximum length of s is 1000. Example: ...
分类:其他好文   时间:2017-12-20 03:40:57    阅读次数:216
Given a string, find the length of the longest substring without repeating characters.(给定一个字符串,找到最长的子串的长度,这个子串不存在重复的字符。 )
Given a string, find the length of the longest substring without repeating characters. Examples: Given "abcabcbb", the answer is "abc", which the leng ...
分类:其他好文   时间:2017-12-19 12:30:29    阅读次数:210
Leetcode:5- Longest Palindromic Substring
Given a string s, find the longest palindromic substring in s. You may assume that the maximum length of s is 1000. Example: Example: 题意:找到一个字符串的最长回文子 ...
分类:其他好文   时间:2017-12-18 19:10:59    阅读次数:144
Leetcode 159: Longest Substring with At Most Two Distinct Characters
Given a string, find the length of the longest substring T that contains at most 2 distinct characters. For example, Given s = “eceba”, T is "ece" whi ...
分类:其他好文   时间:2017-12-18 12:40:29    阅读次数:199
Longest Common Prefix
class Solution(object): def isSamechar(self,strs,pos): if(len(strs[0])<=pos): return False else: for i in range(1,len(strs)): if len(strs[i... ...
分类:其他好文   时间:2017-12-16 16:02:44    阅读次数:181
565. Array Nesting 阵列嵌套
A zero-indexed array A of length N contains all integers from 0 to N-1. Find and return the longest length of set S, where S[i] = {A[i], A[A[i]], A[A[... ...
分类:其他好文   时间:2017-12-15 23:35:06    阅读次数:175
1040. Longest Symmetric String (25)
Given a string, you are supposed to output the length of the longest symmetric sub-string. For example, given "Is PAT&TAP symmetric?", the longest sym ...
分类:其他好文   时间:2017-12-14 14:56:27    阅读次数:135
3017条   上一页 1 ... 84 85 86 87 88 ... 302 下一页
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!