码迷,mamicode.com
首页 >  
搜索关键字:longest substring wi    ( 8067个结果
leetcode-longest palindromic substring-by 1337c0d3r
Given a string S, find the longest palindromic substring in S.Note:This is Part II of the article:Longest Palindromic Substring. Here, we describe an ...
分类:其他好文   时间:2014-11-12 21:05:22    阅读次数:345
486E - LIS of Sequence(LIS)
题意:给一个长度为n的序列,问每个数关于序列的LIS(longest increasing sequence)是什么角色。这里分了三种:           1、此数没有出现在任意一条LIS中           2、此数出现在至少一条但是不是全部的LIS中           3、此数出现在所有的LIS中 解法:nlgn的LIS算法可以求出以每个i位置结束的LIS长度up[i]。出现在L...
分类:其他好文   时间:2014-11-12 19:45:28    阅读次数:214
mysql存储过程批量删除
SP:BEGIN WHILE instr(_checkstr,_str) 0 DO SELECT sortNum INTO @V FROM InApp_job WHERE jobId = substring(_checkstr,1,instr(_checkstr,_str)-1); DELETE F...
分类:数据库   时间:2014-11-11 20:53:35    阅读次数:217
UVa10000_Longest Paths(最短路SPFA)
解题报告求最长路。用SPFA求最长路,初始化图为零,dis数组也为零#include #include #include #include #include #define inf 99999999#define N 110using namespace std;int mmap[N][N],dis...
分类:其他好文   时间:2014-11-11 12:39:12    阅读次数:117
找出矩阵中含有0最多的一行(find the longest row of zero)
对于一个n*n的矩阵,其中只包含有0,1两种元素且,所有的0都在1之前,请找出矩阵中0最多的一行。(Given an N-by-N matrix of 0s and 1s such that in each row no 0 comes before a 1, find the row with the most 0s in O(N) time.) 初看这题,想到的算法就是每一行都设置一个计...
分类:其他好文   时间:2014-11-10 23:30:00    阅读次数:446
javascript获取当前url中的参数
javascript获取当前页面url中的参数可以使用location的search方法,获取到的是url中?后面的部分,例如http:localhost:8080/Manager/index.jsp?id=1 使用location的search方法可以获取到字符串?id=1;想要获取?后面的键值对可以使用substring方法对其进行截取,截取后获得id=1;需要获得id的值,可以使用spli...
分类:编程语言   时间:2014-11-10 23:28:22    阅读次数:478
org.eclipse.core.internal.resources.ResourceException: A resource exists with a different case:
在使用Eclipse进行开发的时候,出现了如下的问题: Description Resource Path Location Type The project was not built due to "A resource exists with a different case: '/SeenTaoImp_zhV2/bin/seentao'.". Fix the problem, th...
分类:系统相关   时间:2014-11-10 20:02:08    阅读次数:448
Longest Common Prefix
Longest Common PrefixWrite a function to find the longest common prefix string amongst an array of strings. 1 public class Solution { 2 public Str...
分类:其他好文   时间:2014-11-10 19:53:49    阅读次数:228
Wi-Fi广播监听
/** * Wifi广播接收 */ private BroadcastReceiver mNetworkStateReceiver = new BroadcastReceiver() { @Override public void onReceive(Context context, Int...
分类:其他好文   时间:2014-11-10 19:26:54    阅读次数:267
MySQL字符串函数:字符串截取总结
MySQL 字符串截取函数:left(), right(), substring(), substring_index()。还有 mid(), substr()。其中,mid(), substr() 等价于 substring() 函数,substring() 的功能非常强大和灵活。1. 字符串截取...
分类:数据库   时间:2014-11-10 13:32:02    阅读次数:259
© 2014 mamicode.com 版权所有  联系我们:gaon5@hotmail.com
迷上了代码!