cf/mirror

Chips Puzzle

CF
1054E2400· grandmaster1s256 MB⌨ stdin/stdout

Examples

Sample 1of 2
Input
2 2
00 10
01 11
10 01
10 01
Output
4
2 1 1 1
1 1 1 2
1 2 2 2
2 2 2 1
Sample 2of 2
Input
2 3
0 0 0
011 1 0
0 0 1
011 0 0
Output
4
2 2 1 2
1 2 2 2
1 2 1 3
1 3 1 2
1054E.cpp
loading editor…
Ln 11·137 BGNU C++20 (64)