KMP算法 next数组模板
摘要:
void preKMP(String s, int kmpNext[]) { int len = s.length(); int k, j; k = kmpNext[0] = -1; j = 0; while (j < len - 1) { if (k == -1 || s.charAt(j) == 阅读全文
posted @ 2021-09-11 16:26 13rj1115 阅读(38) 评论(0) 推荐(0) 编辑