Data Structures Lerax  v3.0-102-gaf18
Opinionated Data Structures & Algorithms
Loading...
Searching...
No Matches
search.h
Go to the documentation of this file.
1
12
13#ifndef SEARCH_H
14#define SEARCH_H
15
16
17/**********************/
18/* SEARCH ALGORITHMS */
19/**********************/
20
31int search_naive(char *text, const char *pattern);
32
43int search_kmp(char *text, const char *pattern);
44
55int search_bm(char *text, const char *pattern);
56
67int search_kr(char *text, const char *pattern);
68
69
70#endif
int search_kmp(char *text, const char *pattern)
Finds the first occurrence of a pattern in a text using the Knuth-Morris-Pratt (KMP) algorithm.
int search_bm(char *text, const char *pattern)
Finds the first occurrence of a pattern in a text using the Boyer-Moore string searching algorithm.
int search_kr(char *text, const char *pattern)
Finds the first occurrence of a pattern in a text using the Karp-Rabin algorithm.
int search_naive(char *text, const char *pattern)
Finds the first occurrence of a pattern in a text using the naive string searching algorithm.