Partition people into groups to reduce total cost. Cost of group depends on prefix sums. = min cost to partition first people into groups.
Transition: try all splits. QI holds for the cost function. Apply D&C: for layer , compute all in using the recursion. Total: instead of . For , , this is the difference between TLE and AC.