Skip to content

RahulYerramsetti/String-Searching-Algorithms

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

4 Commits
 
 
 
 
 
 
 
 
 
 

Repository files navigation

String-Searching-Algorithms

String Matching Algorithms - Boyer-Moore string matching algorithm, Rabin-Karp algorithm, and Knuth-Morris- Pratt algorithm

The Project is done using Java SE8 and Eclipse Ide.

Requirements:

  1. Java JDK SE7/8
  2. Eclipse IDE ( for java development / JAVA IDE)

To run the project:

  1. Extract code.zip which is containg the project.

  2. Import the project "String-Searching-Algorithms" using the Eclipse IDE.

  3. Navigate to stringmatching package in it (String-Searching-Algorithms\src\stringmatching) to find the four algorithms in it.

  4. The Package contains four java programs: boyerbad.java -- Implementing Boyer Moore bad character heuristic Search algorithm. boyergood.java -- Implementing Boyer Moore good suffix heuristic Search algorithm. KMP_String_Matching.java -- Implementing Knuth-Morris-Pratt Search algorithm. rabinkarp.java -- Implementing Rabin-Karp Search algorithm.

  5. The package also contains two text fies: test.txt -- Containing the complete text on which search is done. pattern.txt -- Containing the pattern/substring to search for on the given text (in test.txt).

  6. Enter the text on which you want to perform search in test.txt file. (All the text should be in Either Upper/ Lower Case)

  7. Enter the pattern to search for in the pattern.txt file. ( The Pattern should be either in upper/lower case same as chosen in test.txt)

  8. Choose the algorithm (file.java) you want to execute, right click and click on run as java application to see the output.

  9. Repeat steps 6 to 8 to run the project on other parameters( different pattern/text/algorithm).

About

String Matching Algorithms - Boyer-Moore string matching algorithm, Rabin-Karp algorithm, and Knuth-Morris- Pratt algorithm

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors

Languages