Python3 implementation to find the maximum product of the digit sum of the consecutive pairs of the subsequence of the length K
import sys NEW_LINE MAX = 100 NEW_LINE dp = [ ] NEW_LINE for i in range ( 1000 ) : NEW_LINE INDENT temp1 = [ ] NEW_LINE for j in range ( MAX ) : NEW_LINE INDENT temp2 = [ ] NEW_LINE for k in range ( MAX ) : NEW_LINE INDENT temp2 . append ( 0 ) NEW_LINE DEDENT temp1 . append ( temp2 ) NEW_LINE DEDENT dp . append ( temp1 ) NEW_LINE DEDENT