1
0
mirror of https://gitee.com/coder-xiaomo/leetcode-problemset synced 2025-09-14 03:41:41 +08:00
Code Issues Projects Releases Wiki Activity GitHub Gitee

add leetcode problem-cn part1

This commit is contained in:
2022-03-27 20:37:52 +08:00
parent 8e542045d1
commit c554fc6908
1285 changed files with 108123 additions and 0 deletions

View File

@@ -0,0 +1,25 @@
<p>给你一个由若干 <code>0</code><code>1</code> 组成的二维网格&nbsp;<code>grid</code>,请你找出边界全部由 <code>1</code> 组成的最大 <strong>正方形</strong> 子网格,并返回该子网格中的元素数量。如果不存在,则返回 <code>0</code></p>
<p>&nbsp;</p>
<p><strong>示例 1</strong></p>
<pre><strong>输入:</strong>grid = [[1,1,1],[1,0,1],[1,1,1]]
<strong>输出:</strong>9
</pre>
<p><strong>示例 2</strong></p>
<pre><strong>输入:</strong>grid = [[1,1,0,0]]
<strong>输出:</strong>1
</pre>
<p>&nbsp;</p>
<p><strong>提示:</strong></p>
<ul>
<li><code>1 &lt;= grid.length &lt;= 100</code></li>
<li><code>1 &lt;= grid[0].length &lt;= 100</code></li>
<li><code>grid[i][j]</code>&nbsp;<code>0</code>&nbsp;&nbsp;<code>1</code></li>
</ul>