Initializing first map ( dp [ 0 ] ) with INT_MAX because for i = 0 , there are no elements in the array to flip
for ( int i = - sum ; i <= sum ; i ++ ) { try { dp [ 0 , i ] = int . MaxValue ; } catch ( Exception e ) { } }