Initialize an auxiliary matrix and fill it with 0 s
dp = [ [ 0 for i in range ( 2 ) ] for j in range ( k ) ] NEW_LINE for i in range ( k ) : NEW_LINE INDENT for j in range ( 2 ) : NEW_LINE INDENT dp [ i ] [ j ] = 0 NEW_LINE DEDENT DEDENT