Count Non Decreasing Arrays With Given Digit Sums
Walk the positions with a table of ways per value, letting each value inherit the running total of smaller values.
Walk the positions with a table of ways per value, letting each value inherit the running total of smaller values.