You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The docs for countRepeats say it should "[c]ount the number of times a sequence is repeated in the input sequence that was used to construct the suffix tree."
This works for some examples - the string "aba" should occur 4 times in "abab abac abad abaa"
λ SuffixTree.countRepeats "aba" $ SuffixTree.construct "abab abac abad abaa"
4
But not for others - the string "aba" should occur 4 times in "bababababab"
This is likely related to issue #4. When constructing trees, it is necessary to terminate the input string with a character that does not occur at any other location in the string. Otherwise, the tree will not have the expected properties. Adding a $ character to the input string in the above example resolves the problem.
The docs for
countRepeats
say it should "[c]ount the number of times a sequence is repeated in the input sequence that was used to construct the suffix tree."This works for some examples - the string "aba" should occur 4 times in "abab abac abad abaa"
But not for others - the string "aba" should occur 4 times in "bababababab"
The text was updated successfully, but these errors were encountered: