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 listJan 1, 2026 07:58Josu San MartinJosu San MartinError
Source Code

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

Challenge History
DateChallengerCostTypeStatus
Sep 7, 2026 14:57C#_user21.73CustomSolution Broken
Run Statistics
#DateScoreWall TimeCPU UserCPU SystemMemoryError
1Sep 7, 2026 14:5709,659,5481,438,00002,117,632expected "10000", got "100 "
2Sep 7, 2026 14:5709,570,5441,438,00002,117,632expected "10000", got "100 "
3Sep 7, 2026 14:5709,499,4281,435,00002,117,632expected "10000", got "100 "
4Jan 1, 2026 07:585,25022,155,6611,050,0001,050,0002,437,120
5Jan 1, 2026 07:585,27521,440,36502,110,0002,437,120
6Jan 1, 2026 07:585,27520,467,5751,055,0001,055,0002,441,216
7Jan 1, 2026 07:585,36517,273,5121,073,0001,073,0002,445,312
8Jan 1, 2026 07:585,42522,905,9601,085,0001,085,0002,433,024
9Jan 1, 2026 07:585,43514,075,3281,087,0001,087,0002,437,120
10Jan 1, 2026 07:585,79316,128,9822,317,00002,531,328
11Jan 1, 2026 07:585,80317,596,5962,321,00002,433,024
12Jan 1, 2026 07:586,03020,670,7141,206,0001,206,0002,433,024