vedant1771 / Hactoberfest2021

Repository for Hactoberfest2021
34 stars 464 forks source link

Finite Automata algorithm for Pattern Searching #570

Open polub opened 2 years ago

polub commented 2 years ago

Given a text txt[0..n-1] and a pattern pat[0..m-1], write a function search(char pat[], char txt[]) that prints all occurrences of pat[] in txt[]. You may assume that n > m.