Slight issue with Border-line test case


#1

If I keep all entries in the path matrix as positive quantities. The expected answer is 1. However, if I have surplus energy at the start, I’ll need a minimum of 0, right?
Essentially, if I have a positive non zero minimum required energy at any cell in a bottom-up approach, I’ll need zero energy, no?