Блог пользователя ycperson

Автор ycperson, история, 4 часа назад, По-английски

I encountered some strange difficulty with this problem: https://mirror.codeforces.com/contest/1714/problem/D. The dp idea is that dp[i] represents the answer for the problem for prefix up to position i. dp[i] takes the longest string with an occurrence ending at position i and then checks the dp answer for all positions within the string occurrence (except at i) and then the position to the left of the beginning of the string occurrence (quite similar to the tutorial solution). However, I am getting wrong answer on test case 9 still. I don't know quite why...

Could someone take a look at this submission to see what is wrong? https://mirror.codeforces.com/contest/1714/submission/293576606 (scroll to bottom for actual code, above is template stuff)

  • Проголосовать: нравится
  • 0
  • Проголосовать: не нравится

»
4 часа назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by ycperson (previous revision, new revision, compare).

»
4 часа назад, # |
  Проголосовать: нравится 0 Проголосовать: не нравится

Auto comment: topic has been updated by ycperson (previous revision, new revision, compare).