Split a String in Balanced Strings
Split a string of L and R characters into as many pieces as possible, where each piece has equal numbers of both letters. The visual shows a running balance that returns to zero at each valid cut.
Split a string of L and R characters into as many pieces as possible, where each piece has equal numbers of both letters. The visual shows a running balance that returns to zero at each valid cut.