Largest Square Submatrix of all 1's C#_user

Find the largest square submatrix consisting entirely of 1s as fast as possible.

Input

A 10,000 x 10,000 matrix of uint8 values (0 or 1) on STDIN.

0, 1, 0, 1, 1
0, 1, 1, 1, 1
0, 0, 1, 0, 0
1, 0, 1, 1, 0

Output

Print the side length of the largest all-ones square submatrix to STDOUT. The answer is guaranteed to be greater than 1.

For the example above, the output is:

2
Back to listMay 31, 2025 22:56vahookvahookError
Source Code

Source code access is restricted. Log in to request access.

Challenge History
DateChallengerCostTypeStatus
Sep 7, 2026 14:40C#_user10.00CustomSolution Broken
Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 7, 2026 14:41015,171,7316,707,00002,113,536expected "10000", got " "
2Sep 7, 2026 14:41014,908,3266,642,00002,113,536expected "10000", got " "
3Sep 7, 2026 14:41015,300,3946,613,00002,113,536expected "10000", got " "
4May 31, 2025 22:5617,63025,676,3556,045,0001,007,0002,531,328
5May 31, 2025 22:5617,64321,834,3356,049,0001,008,0002,482,176
6May 31, 2025 22:5617,68320,721,3596,063,0001,010,0002,486,272
7May 31, 2025 22:5617,75325,152,6806,087,0001,014,0002,486,272
8May 31, 2025 22:5617,83823,257,3626,116,0001,019,0002,269,184
9May 31, 2025 22:5617,89022,711,6696,134,0001,022,0002,531,328
10May 31, 2025 22:5617,89523,821,3246,136,0001,022,0002,531,328
11May 31, 2025 22:5617,95826,083,0496,157,0001,026,0002,531,328
12May 31, 2025 22:5618,05026,093,5146,189,0001,031,0002,531,328