AlgoMaster Logo

Z-Algorithm

text=aabxaab,pattern=aab
0 / 31
algomaster.io
Step:Z-Algorithm: Build Z-array on "aab$aabxaab" (pattern + '$' + text), then find matches.