码迷,mamicode.com
首页 >  
搜索关键字:longest substring    ( 5540个结果
String:求str1包含str2的个数
这里用到String类库里的indexOf()函数和subString()函数。 直接贴源码: ?static?int?countStr(String?str,String?subStr){ ?? ??int?count?=?0; ??if(str.indexOf(subStr)==-1) ???return?0; ...
分类:其他好文   时间:2015-09-15 11:15:51    阅读次数:124
ZOJ 3199 Longest Repeated Substring
Longest Repeated SubstringTime Limit: 5000msMemory Limit: 32768KBThis problem will be judged onZJU. Original ID:319964-bit integer IO format:%lld Java...
分类:其他好文   时间:2015-09-14 22:42:54    阅读次数:288
Longest Palindromic Substring - 字符串中最长的回文字段
需求:Given a stringS, find the longest palindromic substring inS. You may assume that the maximum length ofSis 1000, and there exists one unique longest...
分类:其他好文   时间:2015-09-14 22:27:06    阅读次数:156
mysql字符串分割类似split
mysql字符串分割类似split SELECT?SUBSTRING_INDEX(REVERSE(SUBSTRING_INDEX("aa,bb,cc,dd",?",",?1)),?",",?1);????#aa?? SELECT?SUBSTRING_INDEX(REVERSE(SUBSTRING_INDEX("aa,bb,cc,dd",?",",?2...
分类:数据库   时间:2015-09-14 18:12:26    阅读次数:156
leetcode 104: Maximum Depth of Binary Tree
题目:Given a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path from the root node down to the farthest...
分类:其他好文   时间:2015-09-14 16:46:54    阅读次数:101
常用的字符串、数组、Math方法
1. 字符串str.charAt(index)——找不到,返回空字符串str.indexOf(找东西)——找到了返回一个下标,没找到返回-1str.lastIndexOf()——从后面往前找 同上str.substring(beginIndex[, endIndex])——截取字符串,不包含最后一....
分类:编程语言   时间:2015-09-14 16:46:33    阅读次数:202
SSMS For Beginner Part 22 to 24
Part 22 Built in string functions in sql server 2008Part 23 LEFT, RIGHT, CHARINDEX and SUBSTRING functions in sql serverPart 24 Replicate, Space, Pati...
分类:其他好文   时间:2015-09-14 01:56:59    阅读次数:165
Leetcode Maximum Depth of Binary Tree
Given a binary tree, find its maximum depth.The maximum depth is the number of nodes along the longest path from the root node down to the farthest le...
分类:其他好文   时间:2015-09-14 01:55:44    阅读次数:139
java String分类trim,substring,replaceAll,indexOf使用功能
1、trim性能特征去掉字符串首尾空格,防止不必要的空格导致错误。public class TrimTest{ public static void main(String[] args) { String str1=" cjc"; String str2=" c jc "; System.o...
分类:编程语言   时间:2015-09-13 18:28:22    阅读次数:203
javascript中字符串的常用方法
String substring(start,end): slice(start,end); 这两个函数的第二个参数都是置顶区间的末端设置,而不是该区间的长度, substring对于end为负数的处理都将视为0, 而slice方法则会将它与字符串的长度相加,如: ...
分类:编程语言   时间:2015-09-13 17:10:03    阅读次数:182
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!