pattern matching using only character arrays (KMP algorithm)

Collapse
X
 
  • Time
  • Show
Clear All
new posts
  • Johnp585
    New Member
    • Nov 2006
    • 3

    #1

    pattern matching using only character arrays (KMP algorithm)

    I am stuck i keep on going around in circles over this... I am trying to write a program that takes two arguments. They are both strings. I need to implement the KMP algorithm or something similar using only character arrays to see if the first string is within the second string. If anybody can help or give me some pointers it would be greatly appreciated.
    -thanks
  • r035198x
    MVP
    • Sep 2006
    • 13225

    #2
    Originally posted by Johnp585
    I am stuck i keep on going around in circles over this... I am trying to write a program that takes two arguments. They are both strings. I need to implement the KMP algorithm or something similar using only character arrays to see if the first string is within the second string. If anybody can help or give me some pointers it would be greatly appreciated.
    -thanks
    Am I correct in saying that you want to write the substring method?

    Comment

    Working...