Minimum Number of Swaps to Make the String Balanced
Find the fewest swaps needed to turn a bracket string into a balanced one. The visual tracks the running balance and marks where it dips below zero.
Find the fewest swaps needed to turn a bracket string into a balanced one. The visual tracks the running balance and marks where it dips below zero.