You are viewing a single comment's thread. Return to all comments →
Can someone explain how they did this one? I was able to pass all but one test case. My method was:
1010 -> 1000 0101 -> 0111 0100 -> 1100 0010 -> 0011
And I passed over the array once forward and once in reverse and took the minimum number of swaps of the traversals.
Seems like cookies are disabled on this browser, please enable them to open this website
Beautiful Binary String
You are viewing a single comment's thread. Return to all comments →
Can someone explain how they did this one? I was able to pass all but one test case. My method was:
And I passed over the array once forward and once in reverse and took the minimum number of swaps of the traversals.