algorithm: dynamic programming - assemble
algorithm code commit