Write the pseudo-code for a string-matching algorithm of your choice. Note that it is perfectly fine if
Fantastic news! We've Found the answer you've been seeking!
Question:
- Write the pseudo-code for a string-matching algorithm of your choice. Note that it is perfectly fine if you choose either the Bruteforce or Rabin-Karp algorithm which were discussed in class. If you use one of these algorithms, your pseudo code could look very similar to the one shown in the slides. You are encouraged to modify the pseudo-code to make it more detailed and closer to your real implementation, but having the pseudo-code similar to what is in the slides is Okay and points won't be deducted for that.
- Follow the steps in your pseudocode, and implement the string-matching algorithm using Python. Implementations in other programming languages are also acceptable such as R, Java, or C/C++.
- Analyze the worst-case time complexity for the string-matching algorithm that you have implemented.
What to submit:
- pseudo-code that you wrote
- worst-case time complexity analysis using the pseudocode, including the exact number of steps (or basic operations), and/or the big-O and big-Theta estimates.
- source code for your implementation of the algorithm
- screenshots of your program running and its outputs for at least three different test inputs. If you are using Jupyter Notebook for your implementation of the algorithm, you could submit the .ipynb and .html versions of the notebook instead of screenshots. Make sure that you show outputs for at least three different inputs.
Related Book For
Microeconomics An Intuitive Approach with Calculus
ISBN: 978-0538453257
1st edition
Authors: Thomas Nechyba
Posted Date: