Codeforces and Polygon may be unavailable from December 6, 19:00 (UTC) to December 6, 21:00 (UTC) due to technical maintenance. ×

KIMJONGOOF's blog

By KIMJONGOOF, history, 6 weeks ago, In English

This is the question. https://codeforces.net/contest/1974/problem/E

AC submission -> https://codeforces.net/contest/1974/submission/287177874

WA submission -> https://codeforces.net/contest/1974/submission/287176403

In both my submissions, i have the exact same approach, only diff being in 1 case i use the current dp state to update the next dp states(in the WA submission) and in the AC submission i use previous dp states to update current dp states.

Where am i going wrong?

*Edit -> Resolved

  • Vote: I like it
  • -1
  • Vote: I do not like it

»
6 weeks ago, # |
  Vote: I like it 0 Vote: I do not like it

I hope this little fix helped.

  • »
    »
    6 weeks ago, # ^ |
      Vote: I like it 0 Vote: I do not like it

    WOW!! That was a very dumb mistake.

    Thanks a lot, understood my mistake now.

»
6 weeks ago, # |
  Vote: I like it 0 Vote: I do not like it

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