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 28, 2025 01:41vahookvahookError
Source Code

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

Challenge History
DateChallengerCostTypeStatus
Sep 7, 2026 14:57C#_user10.00CustomSolution Broken
Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 7, 2026 14:58020,843,33512,425,00002,113,536expected "10000", got "248 "
2Sep 7, 2026 14:58020,610,18912,427,00002,113,536expected "10000", got "248 "
3Sep 7, 2026 14:58020,965,01912,439,00002,113,536expected "10000", got "248 "
4May 28, 2025 01:4132,47333,831,35011,990,000999,0002,273,280
5May 28, 2025 01:4132,48534,298,67511,995,000999,0002,486,272
6May 28, 2025 01:4132,51030,445,39912,004,0001,000,0002,486,272
7May 28, 2025 01:4132,58032,193,09412,030,0001,002,0002,478,080
8May 28, 2025 01:4132,60330,735,73212,038,0001,003,0002,273,280
9May 28, 2025 01:4132,63827,569,45612,051,0001,004,0002,486,272
10May 28, 2025 01:4132,71028,735,20612,078,0001,006,0002,486,272
11May 28, 2025 01:4132,76035,212,19512,096,0001,008,0002,273,280
12May 28, 2025 01:4132,79334,966,34812,108,0001,009,0002,273,280