1758. Minimum Changes To Make Alternating Binary String
Description
**Input:** s = "0100"
**Output:** 1
**Explanation:** If you change the last character to '1', s will be "0101", which is alternating.**Input:** s = "10"
**Output:** 0
**Explanation:** s is already alternating.**Input:** s = "1111"
**Output:** 2
**Explanation:** You need two operations to reach "0101" or "1010".ac
Last updated