Problem 2107 · Medium
Keep the most distinct flavors after giving away one contiguous block of k candies.
Open the interactive visualisation