Hello!!! I am new here,so I am sorry if this is not the suitable place for asking questions. The problem that I am talking for is that: http://mirror.codeforces.com/contest/443/problem/B I solved that...but I have a question.
In the 3rd testcase,with "abracadabra" it prints 20,because we will split that to "a bracadabra bracadabra",and N will be 10,where N is phrase[i]=phrase[i+N]
I fixed that,to my solution so it is accepted,but still have this question. If N was 7,we would split the phrase like that: "abracad abracad abracad", so the answer would be 21.(21 > 20)
Could have the answer??? Thank you a lot !!!
A tandem repeat of length 2n is string s, where for any position i (1 ≤ i ≤ n) the following condition fulfills: si = si + n
So, what you shown is not a tandem repeat by definition.
So to be something tandem repeat,should be repeated only two times?? Or I am wrong again??
Yes, it should be repeated exactly to times
Yea but in testcase with "aaabbbb",after the k letters "aaabbbbbbb",b is repeated more than 2 times...
But string "bbb" is repeated twice
Ok,thank you man !!!
you're welcome :)