We use cookies to ensure you have the best browsing experience on our website. Please read our cookie policy for more information about how we use cookies.
Yes, good solution. I did the same on Java. But we still have to check if sequance is already in "happy" condition, because there is a test case in which sequance has not empty positions and has at least pair of each same characters. Without checking on the 'happy' condition, our algorithm doesn't pass this test case
Happy Ladybugs
You are viewing a single comment's thread. Return to all comments →
Yes, good solution. I did the same on Java. But we still have to check if sequance is already in "happy" condition, because there is a test case in which sequance has not empty positions and has at least pair of each same characters. Without checking on the 'happy' condition, our algorithm doesn't pass this test case