#1015 : KMP算法
#include<bits/stdc++.h>
using namespace std;
#define N 1000010
char s[N],p[N];
int sLen,pLen,Next[N];
void getNext(char* p){
Next[0]=-1;
int k=-1,j=0;
while(j<pLen)//这里写j<pLen-1要WA
{
if(k==-1||p[j]==p[k]){
++j,++k;