arrow_back
返回选关
chevron_left
上一关
下一关
chevron_right
Ch.4 · Level 06
KMP 匹配
构建 next 数组,失配时 j ← next[j-1],主串指针 i 不回退。
S / 主串
arrow_back
返回关卡库
KMP 匹配
主串 S="ABABCABAB",模式串 P="ABAB"。先构建 next,再执行 KMP 匹配。
1
⌘ + Enter to run
play_arrow
运行代码
guest@aq-shell:~ (bash)
terminal
skip_previous
play_arrow
skip_next
0 / 0
dock_to_left
terminal
1x