#define I{long p=0,q=0,r=1;for #define J if(p=p*m+s[i],q+=r*s[i],r*=m,p==q) #define K I(j=i;++i