Update DynamicProgramming/MinimumSumPartition.java

Co-authored-by: Du Yuanchao <shellhub.me@gmail.com>
This commit is contained in:
tribbleofjim 2020-09-06 16:52:50 +08:00 committed by GitHub
parent 880240c908
commit 9672ffccfe
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -23,7 +23,7 @@ public class MinimumSumPartition
public static int subSet(int[] arr) {
int n = arr.length;
int sum = getSum(arr);
boolean dp[][] = new boolean[n+1][sum+1];
boolean[][] dp = new boolean[n + 1][sum + 1];
for(int i = 0; i < n; i++){
dp[i][0] = true;
}