suspicious_wow's blog

By suspicious_wow, history, 9 years ago, In English

I am trying to solve this spoj problem related to strings and i am constantly getting time limit exceeded.here is my solution .Any help would be appreciated ! thanks :)

  • Vote: I like it
  • 0
  • Vote: I do not like it

| Write comment?
»
9 years ago, # |
  Vote: I like it 0 Vote: I do not like it

You should notice that taking the substrings then concatenate them is not O(1) but O(|S|), then you method should be O(|S|2)