← ALL NOTES
Math

3666. Minimum Operations to Equalize Binary String

A binary string. Per operation, choose a segment of exactly length k and invert all its bits. Find the minimum number of operations to make the string all ones (or all zeros — "equalize"), or −1 if…

Loading…