public static void Test() { Solution s = new Solution(); Console.WriteLine( s.Largest1BorderedSquare( new int[][] { new [] { 1, 0 }, new [] { 0, 1 }, } ) ); Console.WriteLine( s.Largest1BorderedSquare( new int[][] { new [] { 1, 1, 1 }, new [] { 1, 0, 1 }, new [] { 1, 1, 1 }, } ) ); Console.WriteLine( s.Largest1BorderedSquare( new int[][] { new [] { 1, 1, 0, 0 }, } ) ); }