I've tested all permutations, bainhome, and the test suite results are correct. Test case 4 is due to ABABA and BAAAB, which are two different cases. It is not possible to do the same with test case 5. Since A and B are repeated even times.
3892 Solvers
Project Euler: Problem 1, Multiples of 3 and 5
1491 Solvers
Arrange Vector in descending order
4076 Solvers
163 Solvers
Create a random logical vector of N elements of which M are true.
85 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!