mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-09-02 22:13:28 +08:00
update
This commit is contained in:
@@ -12,7 +12,7 @@
|
||||
"translatedContent": "<p>给定由 <code>n</code> 个字符串组成的数组 <code>strs</code>,其中每个字符串长度相等。</p>\n\n<p>选取一个删除索引序列,对于 <code>strs</code> 中的每个字符串,删除对应每个索引处的字符。</p>\n\n<p>比如,有 <code>strs = [\"abcdef\", \"uvwxyz\"]</code>,删除索引序列 <code>{0, 2, 3}</code>,删除后 <code>strs</code> 为<code>[\"bef\", \"vyz\"]</code>。</p>\n\n<p>假设,我们选择了一组删除索引 <code>answer</code>,那么在执行删除操作之后,最终得到的数组的元素是按 <strong>字典序</strong>(<code>strs[0] <= strs[1] <= strs[2] ... <= strs[n - 1]</code>)排列的,然后请你返回 <code>answer.length</code> 的最小可能值。</p>\n\n<p> </p>\n\n<ol>\n</ol>\n\n<p><strong>示例 1:</strong></p>\n\n<pre>\n<strong>输入:</strong>strs = [\"ca\",\"bb\",\"ac\"]\n<strong>输出:</strong>1\n<strong>解释: </strong>\n删除第一列后,strs = [\"a\", \"b\", \"c\"]。\n现在 strs 中元素是按字典排列的 (即,strs[0] <= strs[1] <= strs[2])。\n我们至少需要进行 1 次删除,因为最初 strs 不是按字典序排列的,所以答案是 1。\n</pre>\n\n<p><strong>示例 2:</strong></p>\n\n<pre>\n<strong>输入:</strong>strs = [\"xc\",\"yb\",\"za\"]\n<strong>输出:</strong>0\n<strong>解释:</strong>\nstrs 的列已经是按字典序排列了,所以我们不需要删除任何东西。\n注意 strs 的行不需要按字典序排列。\n也就是说,strs[0][0] <= strs[0][1] <= ... 不一定成立。\n</pre>\n\n<p><strong>示例 3:</strong></p>\n\n<pre>\n<strong>输入:</strong>strs = [\"zyx\",\"wvu\",\"tsr\"]\n<strong>输出:</strong>3\n<strong>解释:</strong>\n我们必须删掉每一列。\n</pre>\n\n<p> </p>\n\n<p><strong>提示:</strong></p>\n\n<ul>\n\t<li><code>n == strs.length</code></li>\n\t<li><code>1 <= n <= 100</code></li>\n\t<li><code>1 <= strs[i].length <= 100</code></li>\n\t<li><code>strs[i]</code> 由小写英文字母组成</li>\n</ul>\n",
|
||||
"isPaidOnly": false,
|
||||
"difficulty": "Medium",
|
||||
"likes": 66,
|
||||
"likes": 68,
|
||||
"dislikes": 0,
|
||||
"isLiked": null,
|
||||
"similarQuestions": "[]",
|
||||
@@ -149,7 +149,7 @@
|
||||
"__typename": "CodeSnippetNode"
|
||||
}
|
||||
],
|
||||
"stats": "{\"totalAccepted\": \"3.8K\", \"totalSubmission\": \"11.3K\", \"totalAcceptedRaw\": 3840, \"totalSubmissionRaw\": 11277, \"acRate\": \"34.1%\"}",
|
||||
"stats": "{\"totalAccepted\": \"4K\", \"totalSubmission\": \"11.7K\", \"totalAcceptedRaw\": 4012, \"totalSubmissionRaw\": 11746, \"acRate\": \"34.2%\"}",
|
||||
"hints": [],
|
||||
"solution": null,
|
||||
"status": null,
|
||||
|
Reference in New Issue
Block a user