Search
⌘K

Leetcode 1052. Grumpy Bookstore Owner

Given arrays customers and grumpy and an integer minutes, maximize total satisfied customers by choosing one contiguous minutes-long window to turn grumpy minutes into non-grumpy; compute the baseline satisfied customers (where grumpy==0) and add the maximum sum of customers on grumpy==1 within any window (sliding-window).


Question Timeline

See when this question was last asked and where, including any notes left by other candidates.

Your account is free and you can post anonymously if you choose.