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 listJun 1, 2025 20:27zielajzielajError
Source Code

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

Challenge History
DateChallengerCostTypeStatus
Sep 7, 2026 14:45C#_user10.00CustomSolution Broken
Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 7, 2026 14:46010,195,3821,212,00002,121,728expected "10000", got "50 "stderr
2Sep 7, 2026 14:4609,597,5291,293,00002,121,728expected "10000", got "50 "stderr
3Sep 7, 2026 14:4609,593,7321,247,00002,121,728expected "10000", got "50 "stderr
4Jun 1, 2025 20:304,01515,587,66901,606,0002,420,736
5Jun 1, 2025 20:274,05817,644,0581,623,00002,424,832
6Jun 1, 2025 20:304,34823,528,78201,739,0002,424,832
7Jun 1, 2025 20:304,41319,095,2671,765,00002,424,832
8Jun 1, 2025 20:304,80314,824,2951,921,00002,424,832
9Jun 1, 2025 20:304,88518,917,64101,954,0002,420,736
10Jun 1, 2025 20:304,91016,663,72001,964,0002,424,832
11Jun 1, 2025 20:304,91322,975,82001,965,0002,424,832
12Jun 1, 2025 20:275,11019,617,61302,044,0002,416,640
13Jun 1, 2025 20:275,13019,425,9121,026,0001,026,0002,420,736
14Jun 1, 2025 20:305,15017,448,3741,030,0001,030,0002,277,376
15Jun 1, 2025 20:305,18517,944,3851,037,0001,037,0002,420,736