← ALL NOTES
String

87. Scramble String

A recursion with the two moves the definition allows. s2 is a scramble of s1 if there's a split point i where either (no swap) the left parts match and the right parts match, or (swap) s1's left…

Loading…