Skip to content

Instantly share code, notes, and snippets.

@Ifihan
Created January 18, 2025 22:25
Show Gist options
  • Save Ifihan/055ba93f0815f5d92459f59fcfe2a68c to your computer and use it in GitHub Desktop.
Save Ifihan/055ba93f0815f5d92459f59fcfe2a68c to your computer and use it in GitHub Desktop.
Minimum Cost to Make at Least One Valid Path in a Grid

Question

Approach

Nothing much to see here. I couldn't think of any proper solution (the question is in the hard difficutly range imo) so I checked the editorial.

Everything can be found there. I followed the Dynamic Programming solution

image
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment