摘要:        
传送门http://poj.org/problem?id=2752题目大意:求既是前缀又是后缀的前缀的可能的长度。。同样是KMP,和 HDU 2594 Simpsons’ Hidden Talents ( http://blog.csdn.net/murmured/article/details/...    阅读全文
posted @ 2013-10-19 14:16
hr_whisper
阅读(153)
评论(0)
推荐(0)
        
            
        
        
摘要:        
传送门http://poj.org/problem?id=2406题目就是求循环了几次。记得如果每循环输出为1.。。。#include#includeconst int MAXN=1000000+10;char P[MAXN];int f[MAXN];int n,m;void getFail(){ ...    阅读全文
posted @ 2013-10-19 09:30
hr_whisper
阅读(145)
评论(0)
推荐(0)
        
            
        
        
摘要:        
传送门http://acm.hdu.edu.cn/showproblem.php?pid=2594题目要求的是求第一个字符串的前缀是第二个字符串的后缀。当然要求最长我还以为是第一个字符串在第二个字符串出现,不用后缀。。。。。。WA了一次。。看题要仔细。。。。根据KMP字符查找过程中,会有一个状态值j...    阅读全文
posted @ 2013-10-19 08:49
hr_whisper
阅读(114)
评论(0)
推荐(0)
        
                    
                
浙公网安备 33010602011771号