Leetcode 2379. Minimum Recolors to Get K Consecutive Black Blocks
Given a string of 'W'/'B' blocks and an integer k, compute the minimum number of white blocks you must recolor so some contiguous substring of length k is all black — equivalently, slide a length-k window and minimize the count of 'W' inside it.
Question Timeline
See when this question was last asked and where, including any notes left by other candidates.
0
Hello Interview Premium
Your account is free and you can post anonymously if you choose.