Solved Minimum path sum problem with DP mehtod with an Running array