ptrus/suffix-trees

Not Generalized Suffix Trees fro multiple strings.

NidhiRustagi opened this issue · 1 comments

Hi!
I tried using the code fro multiple strings, but it fails to give the correct answer. I believe the current implementation is only meant for a single string unless I made some mistake in the function call.
Pasting my code below for your reference:

text = ["how are you doing?", "how are you?", "good morning", "good morning madam"] st = STree.STree(text) st.find("how are you?")

It will be really great if you could add the implementation for multiple strings as well.

ptrus commented

Hi! You should be also able to find multiple occurrences using the find_all method.

text = ["how are you doing?", "how are you?", "good morning", "good morning madam"]
st = STree.STree(text)
st.find_all("how are you")
{0, 19}