0028. Find the Index of the First Occurrence in a String
Interactive visualization of string matching algorithms
Brute Force
KMP Algorithm
Haystack
Needle
sadbutsad / sad
leetcode / leeto
hello / llo
mississippi / issip
aaabaaab / aaab
abcabcabd / abcabd
Step
Play
Reset
Speed:
5x
Press Step or Play to begin