Driver Code
static public void Main ( ) { int [ ] arr = { 12 , 3 , 5 , 6 , 7 , 17 } ; int K = 2 ; int N = arr . Length ; for ( int i = 0 ; i < 100 ; i ++ ) { for ( int j = 0 ; j < 100 ; j ++ ) { for ( int k = 0 ; k < 100 ; k ++ ) { dp [ i , j , k ] = - 1 ; } } } Console . WriteLine ( minSumDifference ( arr , N - 1 , K , K , 0 , 0 ) ) ; } }