Given a matrix, find the minimal path sum from the top left to the bottom right by only moving to the right and down.
For example,
x=[ 2 2 2 2 2
10 10 10 1 2
20 20 20 1 2
30 30 30 30 2]Here, the minimum path sum is 14 [ 2+2+2+2+1+1+2+2 ]
Solution Stats
Solution Comments
Show comments
Loading...
Problem Recent Solvers15
Suggested Problems
-
Select every other element of a vector
36269 Solvers
-
Find all elements less than 0 or greater than 10 and replace them with NaN
15782 Solvers
-
Remove all the words that end with "ain"
2644 Solvers
-
561 Solvers
-
Back to basics 23 - Triangular matrix
1120 Solvers
More from this Author174
Problem Tags
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!