Minimize flipping of bits in given Binary string to make count of 10 equal to 01
Given binary string str, the task is to choose any index and change into 0 or 1, and do this in minimum steps such that the count of substring 01 is equal to 10. Examples: Input: str = "01101"Output: 01100Explanation: 01 as a substring repeat 2 times in a string, 10 as a substring repeat 1 times in