How to approach this problem?

This post was flagged by the community and is temporarily hidden.

a) the cost varies at each position
b) you should ask for a source, the fact that they post an image hints that they could be cheating on something

Okay, i got it both cost and source thanks.

So yeah, can you provide a link to this problem (not just an image) so we know you aren’t cheating?

@galencolin I think even this problem is copied from AtCoder’s DP contest. Check this: C - Vacation

1 Like

Guess that solves the problem then (replacing max with min)

yeah, I don’t think this problem should be considered for any contest.