
KMP
Napoleon2004
这个作者很懒,什么都没留下…
展开
-
HDU 2087
#include<cstdio>#include<string>#include<cstring>#include<iostream>using namespace std;int ans,to[1010];void getto(string p) { to[0]=-1; int j=0,k=-1; while(j<p.siz...原创 2018-07-08 11:29:57 · 267 阅读 · 0 评论 -
HDU 1867
#include<bits/stdc++.h>using namespace std;int const M=100010;int to[M];void getto(char *str){ int i=-1,j=0,len=strlen(str); to[0]=-1; while(j<len-1) if(i==-1||str[i]=...原创 2018-07-08 11:31:27 · 223 阅读 · 0 评论