Useful Links
Computer Science
Algorithms and Data Structures
Algorithm Design and Analysis
1. Introduction to Algorithms
2. Algorithm Analysis
3. Brute-Force and Exhaustive Search
4. Divide and Conquer
5. Greedy Algorithms
6. Dynamic Programming
7. Backtracking and Branch-and-Bound
8. Graph Algorithms
9. String Matching Algorithms
10. Computational Complexity Theory
11. Advanced Topics in Algorithm Design
String Matching Algorithms
Problem Statement
Naive String Matching
Algorithm Description
Implementation
Time Complexity Analysis
Worst-Case Examples
The Rabin-Karp Algorithm
Hash Function Design
Rolling Hash Technique
Algorithm Description
Collision Handling
Analysis
Best-Case
Average-Case
Worst-Case
The Knuth-Morris-Pratt Algorithm
Motivation
Prefix Function
Preprocessing Phase
Search Phase
Analysis
Implementation Details
The Boyer-Moore Algorithm
Bad Character Heuristic
Good Suffix Heuristic
Preprocessing Phase
Search Phase
Analysis
Implementation Considerations
Finite Automata for String Matching
Automaton Construction
Matching Process
Analysis
Multiple Pattern Matching
Aho-Corasick Algorithm
Trie Construction
Failure Function
Pattern Matching Process
Previous
8. Graph Algorithms
Go to top
Next
10. Computational Complexity Theory