摘要: void get_next(string t){ nex[0] = -1; for(int i = 0,k = -1;i < lent;){ if(k 1||t[i] == t[k]){ ++k;++i; nex[i]=k; }else k = nex[k]; } } bool kmp(string 阅读全文
posted @ 2018-06-02 15:09 buerdepepeqi 阅读(112) 评论(0) 推荐(0) 编辑