Stores the dp states
var dp = Array . from ( Array ( 101 ) , ( ) => Array ( 101 ) ) ; for ( var i = 0 ; i < 101 ; i ++ ) for ( var j = 0 ; j < 101 ; j ++ ) dp [ i ] [ j ] = new Array ( 1001 ) . fill ( 0 ) ;