We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
not sure if I understand correctly and wondering in example "ababa" why substring "baba" and "abab" are invalid border?
the explaination is confuse me too??
s= ababa has 15 substrings but only 4 substrings have palindromic borders.
s1…3= aba ⟶P(s1…3)=1
s1…5= ababa ⟶P(s1…5)=2
s2…4= bab ⟶P(s2…4)=1
s3…5= aba ⟶P(s3…5)=1
it says only 4 substring have palindromic borders. but base on the output above, it should be 5.
Palindromic Border
You are viewing a single comment's thread. Return to all comments →
not sure if I understand correctly and wondering in example "ababa" why substring "baba" and "abab" are invalid border? the explaination is confuse me too?? s= ababa has 15 substrings but only 4 substrings have palindromic borders.
s1…3= aba ⟶P(s1…3)=1 s1…5= ababa ⟶P(s1…5)=2 s2…4= bab ⟶P(s2…4)=1 s3…5= aba ⟶P(s3…5)=1
it says only 4 substring have palindromic borders. but base on the output above, it should be 5.