Kyochi's blog

By Kyochi, history, 5 years ago, In English

Hello CF, I need help to figure out how to solve this problem. i'm not able to get the recurence relation as well as the dp starting state. Someone can explain me how to figure it out the problem ?

https://questionsacm.isograd.com/codecontest/pdf/toughcorridor.pdf

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

»
5 years ago, # |
  Vote: I like it +11 Vote: I do not like it

Rather than trying to think about the DP solution straight away, ask what is the brute force solution first? Then do a transformation from the brute force to the DP solution.