This problem needs more test cases with the three of a kind appearing before the pair, such as:
1 0 1 0 0 0 0 0 0 0 1 0 1
0 0 0 0 0 0 0 0 0 0 0 0 0
0 0 1 0 0 0 0 0 0 0 1 0 0
0 0 0 0 0 0 0 0 0 0 1 0 0
12400 Solvers
What is the next step in Conway's Life?
640 Solvers
309 Solvers
Create a square matrix of multiples
383 Solvers
402 Solvers
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!