Problem 3218 · Medium

Minimum Cost for Cutting Cake I

Make the most expensive cuts first; each cut is paid once for every piece it crosses, so the piece counts on the other axis multiply it.

Open the interactive visualisation