Skip to content

Commit 2862a22

Browse files
committed
移除零宽空格
1 parent 440092a commit 2862a22

File tree

43 files changed

+52
-52
lines changed

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

43 files changed

+52
-52
lines changed

leetcode-cn/originData/best-time-to-buy-and-sell-stock-using-strategy.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

leetcode-cn/originData/earliest-finish-time-for-land-and-water-rides-i.json

Lines changed: 2 additions & 2 deletions
Large diffs are not rendered by default.

leetcode-cn/originData/earliest-finish-time-for-land-and-water-rides-ii.json

Lines changed: 1 addition & 1 deletion
Large diffs are not rendered by default.

leetcode-cn/originData/find-the-least-frequent-digit.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"boundTopicId": 3767153,
88
"title": "Find The Least Frequent Digit",
99
"titleSlug": "find-the-least-frequent-digit",
10-
"content": "<p>Given an integer <code>n</code>, find the digit that occurs <strong>least</strong> frequently in its decimal representation. If multiple digits have the same frequency, choose the <strong>smallest</strong> digit.</p>\n\n<p>Return the chosen digit as an integer.</p>\nThe <strong>frequency</strong> of a digit <code>x</code> is the number of times it appears in the decimal representation of <code>n</code>.\n<p>&nbsp;</p>\n<p><strong class=\"example\">Example 1:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">n = 1553322</span></p>\n\n<p><strong>Output:</strong> 1</p>\n\n<p><strong>Explanation:</strong></p>\n\n<p>The least frequent digit in <code>n</code> is 1, which appears only once. All other digits appear twice.</p>\n</div>\n\n<p><strong class=\"example\">Example 2:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">n = 723344511</span></p>\n\n<p><strong>Output:</strong> 2</p>\n\n<p><strong>Explanation:</strong></p>\n\n<p>The least frequent digits in <code>n</code> are 7, 2, and 5; each appears only once.</p>\n</div>\n\n<p>&nbsp;</p>\n<p><strong>Constraints:</strong></p>\n\n<ul>\n\t<li><code>1 &lt;= n &lt;= 2<sup>31</sup>​​​​​​​ - 1</code></li>\n</ul>\n",
10+
"content": "<p>Given an integer <code>n</code>, find the digit that occurs <strong>least</strong> frequently in its decimal representation. If multiple digits have the same frequency, choose the <strong>smallest</strong> digit.</p>\n\n<p>Return the chosen digit as an integer.</p>\nThe <strong>frequency</strong> of a digit <code>x</code> is the number of times it appears in the decimal representation of <code>n</code>.\n<p>&nbsp;</p>\n<p><strong class=\"example\">Example 1:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">n = 1553322</span></p>\n\n<p><strong>Output:</strong> 1</p>\n\n<p><strong>Explanation:</strong></p>\n\n<p>The least frequent digit in <code>n</code> is 1, which appears only once. All other digits appear twice.</p>\n</div>\n\n<p><strong class=\"example\">Example 2:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">n = 723344511</span></p>\n\n<p><strong>Output:</strong> 2</p>\n\n<p><strong>Explanation:</strong></p>\n\n<p>The least frequent digits in <code>n</code> are 7, 2, and 5; each appears only once.</p>\n</div>\n\n<p>&nbsp;</p>\n<p><strong>Constraints:</strong></p>\n\n<ul>\n\t<li><code>1 &lt;= n &lt;= 2<sup>31</sup> - 1</code></li>\n</ul>\n",
1111
"translatedTitle": "出现频率最低的数字",
1212
"translatedContent": "<p>给你一个整数 <code>n</code>,找出在其十进制表示中出现频率&nbsp;<strong>最低&nbsp;</strong>的数字。如果多个数字的出现频率相同,则选择&nbsp;<strong>最小&nbsp;</strong>的那个数字。</p>\n\n<p>以整数形式返回所选的数字。</p>\n\n<p>数字 <code>x</code> 的出现频率是指它在&nbsp;<code>n</code> 的十进制表示中的出现次数。</p>\n\n<p>&nbsp;</p>\n\n<p><strong class=\"example\">示例 1:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>输入:</strong> <span class=\"example-io\">n = 1553322</span></p>\n\n<p><strong>输出:</strong> 1</p>\n\n<p><strong>解释:</strong></p>\n\n<p>在 <code>n</code> 中,出现频率最低的数字是 1,它只出现了一次。所有其他数字都出现了两次。</p>\n</div>\n\n<p><strong class=\"example\">示例 2:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>输入:</strong> <span class=\"example-io\">n = 723344511</span></p>\n\n<p><strong>输出:</strong> 2</p>\n\n<p><strong>解释:</strong></p>\n\n<p>在 <code>n</code> 中,出现频率最低的数字是 7、2 和 5,它们都只出现了一次。</p>\n</div>\n\n<p>&nbsp;</p>\n\n<p><strong>提示:</strong></p>\n\n<ul>\n\t<li><code>1 &lt;= n &lt;= 2<sup>31</sup> - 1</code></li>\n</ul>\n",
1313
"isPaidOnly": false,

leetcode-cn/originData/flip-square-submatrix-vertically.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"boundTopicId": 3746533,
88
"title": "Flip Square Submatrix Vertically",
99
"titleSlug": "flip-square-submatrix-vertically",
10-
"content": "<p>You are given an <code>m x n</code> integer matrix <code>grid</code>, and three integers <code>x</code>, <code>y</code>, and <code>k</code>.</p>\n\n<p>The integers <code>x</code> and <code>y</code> represent the row and column indices of the <strong>top-left</strong> corner of a <strong>square</strong> submatrix and the integer <code>k</code> represents the size (side length) of the square submatrix.</p>\n\n<p>Your task is to flip the submatrix by reversing the order of its rows vertically.</p>\n\n<p>Return the updated matrix.</p>\n\n<p>&nbsp;</p>\n<p><strong class=\"example\">Example 1:</strong></p>\n<img alt=\"\" src=\"https://assets.leetcode.com/uploads/2025/07/20/gridexmdrawio.png\" style=\"width: 300px; height: 116px;\" />\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">grid = </span>[[1,2,3,4],[5,6,7,8],[9,10,11,12],[13,14,15,16]]<span class=\"example-io\">, x = 1, y = 0, k = 3</span></p>\n\n<p><strong>Output:</strong> <span class=\"example-io\">[[1,2,3,4],[13,14,15,8],[9,10,11,12],[5,6,7,16]]</span></p>\n\n<p><strong>Explanation:</strong></p>\n\n<p>The diagram above shows the grid before and after the transformation.</p>\n</div>\n\n<p><strong class=\"example\">Example 2:</strong></p>\n<img alt=\"\" src=\"https://assets.leetcode.com/uploads/2025/07/20/gridexm2drawio.png\" style=\"width: 350px; height: 68px;\" />​​​​​​​\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">grid = [[3,4,2,3],[2,3,4,2]], x = 0, y = 2, k = 2</span></p>\n\n<p><strong>Output:</strong> <span class=\"example-io\">[[3,4,4,2],[2,3,2,3]]</span></p>\n\n<p><strong>Explanation:</strong></p>\n\n<p>The diagram above shows the grid before and after the transformation.</p>\n</div>\n\n<p>&nbsp;</p>\n<p><strong>Constraints:</strong></p>\n\n<ul>\n\t<li><code>m == grid.length</code></li>\n\t<li><code>n == grid[i].length</code></li>\n\t<li><code>1 &lt;= m, n &lt;= 50</code></li>\n\t<li><code>1 &lt;= grid[i][j] &lt;= 100</code></li>\n\t<li><code>0 &lt;= x &lt; m</code></li>\n\t<li><code>0 &lt;= y &lt; n</code></li>\n\t<li><code>1 &lt;= k &lt;= min(m - x, n - y)</code></li>\n</ul>\n",
10+
"content": "<p>You are given an <code>m x n</code> integer matrix <code>grid</code>, and three integers <code>x</code>, <code>y</code>, and <code>k</code>.</p>\n\n<p>The integers <code>x</code> and <code>y</code> represent the row and column indices of the <strong>top-left</strong> corner of a <strong>square</strong> submatrix and the integer <code>k</code> represents the size (side length) of the square submatrix.</p>\n\n<p>Your task is to flip the submatrix by reversing the order of its rows vertically.</p>\n\n<p>Return the updated matrix.</p>\n\n<p>&nbsp;</p>\n<p><strong class=\"example\">Example 1:</strong></p>\n<img alt=\"\" src=\"https://assets.leetcode.com/uploads/2025/07/20/gridexmdrawio.png\" style=\"width: 300px; height: 116px;\" />\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">grid = </span>[[1,2,3,4],[5,6,7,8],[9,10,11,12],[13,14,15,16]]<span class=\"example-io\">, x = 1, y = 0, k = 3</span></p>\n\n<p><strong>Output:</strong> <span class=\"example-io\">[[1,2,3,4],[13,14,15,8],[9,10,11,12],[5,6,7,16]]</span></p>\n\n<p><strong>Explanation:</strong></p>\n\n<p>The diagram above shows the grid before and after the transformation.</p>\n</div>\n\n<p><strong class=\"example\">Example 2:</strong></p>\n<img alt=\"\" src=\"https://assets.leetcode.com/uploads/2025/07/20/gridexm2drawio.png\" style=\"width: 350px; height: 68px;\" />\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">grid = [[3,4,2,3],[2,3,4,2]], x = 0, y = 2, k = 2</span></p>\n\n<p><strong>Output:</strong> <span class=\"example-io\">[[3,4,4,2],[2,3,2,3]]</span></p>\n\n<p><strong>Explanation:</strong></p>\n\n<p>The diagram above shows the grid before and after the transformation.</p>\n</div>\n\n<p>&nbsp;</p>\n<p><strong>Constraints:</strong></p>\n\n<ul>\n\t<li><code>m == grid.length</code></li>\n\t<li><code>n == grid[i].length</code></li>\n\t<li><code>1 &lt;= m, n &lt;= 50</code></li>\n\t<li><code>1 &lt;= grid[i][j] &lt;= 100</code></li>\n\t<li><code>0 &lt;= x &lt; m</code></li>\n\t<li><code>0 &lt;= y &lt; n</code></li>\n\t<li><code>1 &lt;= k &lt;= min(m - x, n - y)</code></li>\n</ul>\n",
1111
"translatedTitle": "垂直翻转子矩阵",
1212
"translatedContent": "<p>给你一个 <code>m x n</code> 的整数矩阵 <code>grid</code>,以及三个整数 <code>x</code>、<code>y</code> 和 <code>k</code>。</p>\n\n<p>整数 <code>x</code> 和 <code>y</code> 表示一个&nbsp;<strong>正方形子矩阵&nbsp;</strong>的左上角下标,整数 <code>k</code> 表示该正方形子矩阵的边长。</p>\n\n<p>你的任务是垂直翻转子矩阵的行顺序。</p>\n\n<p>返回更新后的矩阵。</p>\n\n<p>&nbsp;</p>\n\n<p><strong class=\"example\">示例 1:</strong></p>\n<img alt=\"\" src=\"https://assets.leetcode.com/uploads/2025/07/20/gridexmdrawio.png\" style=\"width: 300px; height: 116px;\" />\n<div class=\"example-block\">\n<p><strong>输入:</strong> <span class=\"example-io\">grid = </span>[[1,2,3,4],[5,6,7,8],[9,10,11,12],[13,14,15,16]]<span class=\"example-io\">, x = 1, y = 0, k = 3</span></p>\n\n<p><strong>输出:</strong> <span class=\"example-io\">[[1,2,3,4],[13,14,15,8],[9,10,11,12],[5,6,7,16]]</span></p>\n\n<p><strong>解释:</strong></p>\n\n<p>上图展示了矩阵在变换前后的样子。</p>\n</div>\n\n<p><strong class=\"example\">示例 2:</strong></p>\n<img alt=\"\" src=\"https://assets.leetcode.com/uploads/2025/07/20/gridexm2drawio.png\" style=\"width: 350px; height: 68px;\" />\n<div class=\"example-block\">\n<p><strong>输入:</strong> <span class=\"example-io\">grid = [[3,4,2,3],[2,3,4,2]], x = 0, y = 2, k = 2</span></p>\n\n<p><strong>输出:</strong> <span class=\"example-io\">[[3,4,4,2],[2,3,2,3]]</span></p>\n\n<p><strong>解释:</strong></p>\n\n<p>上图展示了矩阵在变换前后的样子。</p>\n</div>\n\n<p>&nbsp;</p>\n\n<p><strong>提示:</strong></p>\n\n<ul>\n\t<li><code>m == grid.length</code></li>\n\t<li><code>n == grid[i].length</code></li>\n\t<li><code>1 &lt;= m, n &lt;= 50</code></li>\n\t<li><code>1 &lt;= grid[i][j] &lt;= 100</code></li>\n\t<li><code>0 &lt;= x &lt; m</code></li>\n\t<li><code>0 &lt;= y &lt; n</code></li>\n\t<li><code>1 &lt;= k &lt;= min(m - x, n - y)</code></li>\n</ul>\n",
1313
"isPaidOnly": false,

leetcode-cn/originData/gcd-of-odd-and-even-sums.json

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@
77
"boundTopicId": 3761282,
88
"title": "GCD of Odd and Even Sums",
99
"titleSlug": "gcd-of-odd-and-even-sums",
10-
"content": "<p>You are given an integer <code>n</code>. Your task is to compute the <strong>GCD</strong> (greatest common divisor) of two values:</p>\n\n<ul>\n\t<li>\n\t<p><code>sumOdd</code>: the sum of the first <code>n</code> odd numbers.</p>\n\t</li>\n\t<li>\n\t<p><code>sumEven</code>: the sum of the first <code>n</code> even numbers.</p>\n\t</li>\n</ul>\n\n<p>Return the GCD of <code>sumOdd</code> and <code>sumEven</code>.</p>\n\n<p>&nbsp;</p>\n<p><strong class=\"example\">Example 1:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">n = 4</span></p>\n\n<p><strong>Output:</strong> <span class=\"example-io\">4</span></p>\n\n<p><strong>Explanation:</strong></p>\n\n<ul>\n\t<li>Sum of the first 4 odd numbers <code>sumOdd = 1 + 3 + 5 + 7 = 16</code></li>\n\t<li>Sum of the first 4 even numbers <code>sumEven = 2 + 4 + 6 + 8 = 20</code></li>\n</ul>\n\n<p>Hence, <code>GCD(sumOdd, sumEven) = GCD(16, 20) = 4</code>.</p>\n</div>\n\n<p><strong class=\"example\">Example 2:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">n = 5</span></p>\n\n<p><strong>Output:</strong> <span class=\"example-io\">5</span></p>\n\n<p><strong>Explanation:</strong></p>\n\n<ul>\n\t<li>Sum of the first 5 odd numbers <code>sumOdd = 1 + 3 + 5 + 7 + 9 = 25</code></li>\n\t<li>Sum of the first 5 even numbers <code>sumEven = 2 + 4 + 6 + 8 + 10 = 30</code></li>\n</ul>\n\n<p>Hence, <code>GCD(sumOdd, sumEven) = GCD(25, 30) = 5</code>.</p>\n</div>\n\n<p>&nbsp;</p>\n<p><strong>Constraints:</strong></p>\n\n<ul>\n\t<li><code>1 &lt;= n &lt;= 10​​​​​​​00</code></li>\n</ul>\n",
10+
"content": "<p>You are given an integer <code>n</code>. Your task is to compute the <strong>GCD</strong> (greatest common divisor) of two values:</p>\n\n<ul>\n\t<li>\n\t<p><code>sumOdd</code>: the sum of the first <code>n</code> odd numbers.</p>\n\t</li>\n\t<li>\n\t<p><code>sumEven</code>: the sum of the first <code>n</code> even numbers.</p>\n\t</li>\n</ul>\n\n<p>Return the GCD of <code>sumOdd</code> and <code>sumEven</code>.</p>\n\n<p>&nbsp;</p>\n<p><strong class=\"example\">Example 1:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">n = 4</span></p>\n\n<p><strong>Output:</strong> <span class=\"example-io\">4</span></p>\n\n<p><strong>Explanation:</strong></p>\n\n<ul>\n\t<li>Sum of the first 4 odd numbers <code>sumOdd = 1 + 3 + 5 + 7 = 16</code></li>\n\t<li>Sum of the first 4 even numbers <code>sumEven = 2 + 4 + 6 + 8 = 20</code></li>\n</ul>\n\n<p>Hence, <code>GCD(sumOdd, sumEven) = GCD(16, 20) = 4</code>.</p>\n</div>\n\n<p><strong class=\"example\">Example 2:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>Input:</strong> <span class=\"example-io\">n = 5</span></p>\n\n<p><strong>Output:</strong> <span class=\"example-io\">5</span></p>\n\n<p><strong>Explanation:</strong></p>\n\n<ul>\n\t<li>Sum of the first 5 odd numbers <code>sumOdd = 1 + 3 + 5 + 7 + 9 = 25</code></li>\n\t<li>Sum of the first 5 even numbers <code>sumEven = 2 + 4 + 6 + 8 + 10 = 30</code></li>\n</ul>\n\n<p>Hence, <code>GCD(sumOdd, sumEven) = GCD(25, 30) = 5</code>.</p>\n</div>\n\n<p>&nbsp;</p>\n<p><strong>Constraints:</strong></p>\n\n<ul>\n\t<li><code>1 &lt;= n &lt;= 1000</code></li>\n</ul>\n",
1111
"translatedTitle": "奇数和与偶数和的最大公约数",
1212
"translatedContent": "<p>给你一个整数 <code>n</code>。请你计算以下两个值的&nbsp;<strong>最大公约数</strong>(GCD):</p>\n\n<ul>\n\t<li>\n\t<p><code>sumOdd</code>:前 <code>n</code> 个奇数的总和。</p>\n\t</li>\n\t<li>\n\t<p><code>sumEven</code>:前 <code>n</code> 个偶数的总和。</p>\n\t</li>\n</ul>\n\n<p>返回 <code>sumOdd</code> 和 <code>sumEven</code> 的 GCD。</p>\n\n<p>&nbsp;</p>\n\n<p><strong class=\"example\">示例 1:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>输入:</strong> <span class=\"example-io\">n = 4</span></p>\n\n<p><strong>输出:</strong> <span class=\"example-io\">4</span></p>\n\n<p><strong>解释:</strong></p>\n\n<ul>\n\t<li>前 4 个奇数的总和 <code>sumOdd = 1 + 3 + 5 + 7 = 16</code></li>\n\t<li>前 4 个偶数的总和 <code>sumEven = 2 + 4 + 6 + 8 = 20</code></li>\n</ul>\n\n<p>因此,<code>GCD(sumOdd, sumEven) = GCD(16, 20) = 4</code>。</p>\n</div>\n\n<p><strong class=\"example\">示例 2:</strong></p>\n\n<div class=\"example-block\">\n<p><strong>输入:</strong> <span class=\"example-io\">n = 5</span></p>\n\n<p><strong>输出:</strong> <span class=\"example-io\">5</span></p>\n\n<p><strong>解释:</strong></p>\n\n<ul>\n\t<li>前 5 个奇数的总和 <code>sumOdd = 1 + 3 + 5 + 7 + 9 = 25</code></li>\n\t<li>前 5 个偶数的总和 <code>sumEven = 2 + 4 + 6 + 8 + 10 = 30</code></li>\n</ul>\n\n<p>因此,<code>GCD(sumOdd, sumEven) = GCD(25, 30) = 5</code>。</p>\n</div>\n\n<p>&nbsp;</p>\n\n<p><strong>提示:</strong></p>\n\n<ul>\n\t<li><code>1 &lt;= n &lt;= 1000</code></li>\n</ul>\n",
1313
"isPaidOnly": false,

0 commit comments

Comments
 (0)