mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-09-05 15:31:43 +08:00
update
This commit is contained in:
@@ -0,0 +1,52 @@
|
||||
<p>给你一个长度为偶数下标从 <strong>0</strong> 开始的二进制字符串 <code>s</code> 。</p>
|
||||
|
||||
<p>如果可以将一个字符串分割成一个或者更多满足以下条件的子字符串,那么我们称这个字符串是 <strong>美丽的</strong> :</p>
|
||||
|
||||
<ul>
|
||||
<li>每个子字符串的长度都是 <strong>偶数</strong> 。</li>
|
||||
<li>每个子字符串都 <strong>只</strong> 包含 <code>1</code> 或 <strong>只</strong> 包含 <code>0</code> 。</li>
|
||||
</ul>
|
||||
|
||||
<p>你可以将 <code>s</code> 中任一字符改成 <code>0</code> 或者 <code>1</code> 。</p>
|
||||
|
||||
<p>请你返回让字符串 <code>s</code> 美丽的<strong> 最少</strong> 字符修改次数。</p>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong class="example">示例 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>s = "1001"
|
||||
<b>输出:</b>2
|
||||
<b>解释:</b>我们将 s[1] 改为 1 ,且将 s[3] 改为 0 ,得到字符串 "1100" 。
|
||||
字符串 "1100" 是美丽的,因为我们可以将它分割成 "11|00" 。
|
||||
将字符串变美丽最少需要 2 次修改。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 2:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>s = "10"
|
||||
<b>输出:</b>1
|
||||
<b>解释:</b>我们将 s[1] 改为 1 ,得到字符串 "11" 。
|
||||
字符串 "11" 是美丽的,因为它已经是美丽的。
|
||||
将字符串变美丽最少需要 1 次修改。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 3:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>s = "0000"
|
||||
<b>输出:</b>0
|
||||
<b>解释:</b>不需要进行任何修改,字符串 "0000" 已经是美丽字符串。
|
||||
</pre>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>提示:</strong></p>
|
||||
|
||||
<ul>
|
||||
<li><code>2 <= s.length <= 10<sup>5</sup></code></li>
|
||||
<li><code>s</code> 的长度为偶数。</li>
|
||||
<li><code>s[i]</code> 要么是 <code>'0'</code> ,要么是 <code>'1'</code> 。</li>
|
||||
</ul>
|
@@ -0,0 +1,64 @@
|
||||
<p>给你一个下标从 <strong>0</strong> 开始、长度为 <code>n</code> 的整数数组 <code>nums</code> ,和一个整数 <code>k</code> 。</p>
|
||||
|
||||
<p>你可以执行下述 <strong>递增</strong> 运算 <strong>任意</strong> 次(可以是 <strong>0</strong> 次):</p>
|
||||
|
||||
<ul>
|
||||
<li>从范围 <code>[0, n - 1]</code> 中选择一个下标 <code>i</code> ,并将 <code>nums[i]</code> 的值加 <code>1</code> 。</li>
|
||||
</ul>
|
||||
|
||||
<p>如果数组中任何长度 <strong>大于或等于 3</strong> 的子数组,其 <strong>最大</strong> 元素都大于或等于 <code>k</code> ,则认为数组是一个 <strong>美丽数组</strong> 。</p>
|
||||
|
||||
<p>以整数形式返回使数组变为 <strong>美丽数组</strong> 需要执行的 <strong>最小</strong> 递增运算数。</p>
|
||||
|
||||
<p>子数组是数组中的一个连续 <strong>非空</strong> 元素序列。</p>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong class="example">示例 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>nums = [2,3,0,0,2], k = 4
|
||||
<strong>输出:</strong>3
|
||||
<strong>解释:</strong>可以执行下述递增运算,使 nums 变为美丽数组:
|
||||
选择下标 i = 1 ,并且将 nums[1] 的值加 1 -> [2,4,0,0,2] 。
|
||||
选择下标 i = 4 ,并且将 nums[4] 的值加 1 -> [2,4,0,0,3] 。
|
||||
选择下标 i = 4 ,并且将 nums[4] 的值加 1 -> [2,4,0,0,4] 。
|
||||
长度大于或等于 3 的子数组为 [2,4,0], [4,0,0], [0,0,4], [2,4,0,0], [4,0,0,4], [2,4,0,0,4] 。
|
||||
在所有子数组中,最大元素都等于 k = 4 ,所以 nums 现在是美丽数组。
|
||||
可以证明无法用少于 3 次递增运算使 nums 变为美丽数组。
|
||||
因此,答案为 3 。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 2:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>nums = [0,1,3,3], k = 5
|
||||
<strong>输出:</strong>2
|
||||
<strong>解释:</strong>可以执行下述递增运算,使 nums 变为美丽数组:
|
||||
选择下标 i = 2 ,并且将 nums[2] 的值加 1 -> [0,1,4,3] 。
|
||||
选择下标 i = 2 ,并且将 nums[2] 的值加 1 -> [0,1,5,3] 。
|
||||
长度大于或等于 3 的子数组为 [0,1,5]、[1,5,3]、[0,1,5,3] 。
|
||||
在所有子数组中,最大元素都等于 k = 5 ,所以 nums 现在是美丽数组。
|
||||
可以证明无法用少于 2 次递增运算使 nums 变为美丽数组。
|
||||
因此,答案为 2 。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 3:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>nums = [1,1,2], k = 1
|
||||
<strong>输出:</strong>0
|
||||
<strong>解释:</strong>在这个示例中,只有一个长度大于或等于 3 的子数组 [1,1,2] 。
|
||||
其最大元素 2 已经大于 k = 1 ,所以无需执行任何增量运算。
|
||||
因此,答案为 0 。
|
||||
</pre>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>提示:</strong></p>
|
||||
|
||||
<ul>
|
||||
<li><code>3 <= n == nums.length <= 10<sup>5</sup></code></li>
|
||||
<li><code>0 <= nums[i] <= 10<sup>9</sup></code></li>
|
||||
<li><code>0 <= k <= 10<sup>9</sup></code></li>
|
||||
</ul>
|
@@ -0,0 +1,41 @@
|
||||
<p>给你一个下标从 <strong>0</strong> 开始的整数数组 <code>nums</code> 和一个整数 <code>target</code> 。</p>
|
||||
|
||||
<p>返回和为 <code>target</code> 的 <code>nums</code> 子序列中,子序列 <strong>长度的最大值 </strong>。如果不存在和为 <code>target</code> 的子序列,返回 <code>-1</code> 。</p>
|
||||
|
||||
<p><strong>子序列</strong> 指的是从原数组中删除一些或者不删除任何元素后,剩余元素保持原来的顺序构成的数组。</p>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong class="example">示例 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>nums = [1,2,3,4,5], target = 9
|
||||
<b>输出:</b>3
|
||||
<b>解释:</b>总共有 3 个子序列的和为 9 :[4,5] ,[1,3,5] 和 [2,3,4] 。最长的子序列是 [1,3,5] 和 [2,3,4] 。所以答案为 3 。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 2:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>nums = [4,1,3,2,1,5], target = 7
|
||||
<b>输出:</b>4
|
||||
<strong>解释:</strong>总共有 5 个子序列的和为 7 :[4,3] ,[4,1,2] ,[4,2,1] ,[1,1,5] 和 [1,3,2,1] 。最长子序列为 [1,3,2,1] 。所以答案为 4 。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 3:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>nums = [1,1,5,4,5], target = 3
|
||||
<b>输出:</b>-1
|
||||
<b>解释:</b>无法得到和为 3 的子序列。
|
||||
</pre>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>提示:</strong></p>
|
||||
|
||||
<ul>
|
||||
<li><code>1 <= nums.length <= 1000</code></li>
|
||||
<li><code>1 <= nums[i] <= 1000</code></li>
|
||||
<li><code>1 <= target <= 1000</code></li>
|
||||
</ul>
|
@@ -0,0 +1,51 @@
|
||||
<p>给你一个下标从 <strong>0</strong> 开始的整数数组 <code>nums</code> 。</p>
|
||||
|
||||
<p>定义 <code>nums</code> 一个子数组的 <strong>不同计数</strong> 值如下:</p>
|
||||
|
||||
<ul>
|
||||
<li>令 <code>nums[i..j]</code> 表示 <code>nums</code> 中所有下标在 <code>i</code> 到 <code>j</code> 范围内的元素构成的子数组(满足 <code>0 <= i <= j < nums.length</code> ),那么我们称子数组 <code>nums[i..j]</code> 中不同值的数目为 <code>nums[i..j]</code> 的不同计数。</li>
|
||||
</ul>
|
||||
|
||||
<p>请你返回 <code>nums</code> 中所有子数组的 <strong>不同计数</strong> 的 <strong>平方</strong> 和。</p>
|
||||
|
||||
<p>由于答案可能会很大,请你将它对 <code>10<sup>9</sup> + 7</code> <strong>取余</strong> 后返回。</p>
|
||||
|
||||
<p>子数组指的是一个数组里面一段连续 <strong>非空</strong> 的元素序列。</p>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>示例 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>nums = [1,2,1]
|
||||
<b>输出:</b>15
|
||||
<b>解释:</b>六个子数组分别为:
|
||||
[1]: 1 个互不相同的元素。
|
||||
[2]: 1 个互不相同的元素。
|
||||
[1]: 1 个互不相同的元素。
|
||||
[1,2]: 2 个互不相同的元素。
|
||||
[2,1]: 2 个互不相同的元素。
|
||||
[1,2,1]: 2 个互不相同的元素。
|
||||
所有不同计数的平方和为 1<sup>2</sup> + 1<sup>2</sup> + 1<sup>2</sup> + 2<sup>2</sup> + 2<sup>2</sup> + 2<sup>2</sup> = 15 。
|
||||
</pre>
|
||||
|
||||
<p><strong>示例 2:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>nums = [2,2]
|
||||
<b>输出:3</b>
|
||||
<strong>解释:</strong>三个子数组分别为:
|
||||
[2]: 1 个互不相同的元素。
|
||||
[2]: 1 个互不相同的元素。
|
||||
[2,2]: 1 个互不相同的元素。
|
||||
所有不同计数的平方和为 1<sup>2</sup> + 1<sup>2</sup> + 1<sup>2</sup> = 3 。
|
||||
</pre>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>提示:</strong></p>
|
||||
|
||||
<ul>
|
||||
<li><code>1 <= nums.length <= 100</code></li>
|
||||
<li><code>1 <= nums[i] <= 100</code></li>
|
||||
</ul>
|
@@ -0,0 +1,51 @@
|
||||
<p>给你一个下标从 <strong>0</strong> 开始的整数数组 <code>nums</code> 。</p>
|
||||
|
||||
<p>定义 <code>nums</code> 一个子数组的 <strong>不同计数</strong> 值如下:</p>
|
||||
|
||||
<ul>
|
||||
<li>令 <code>nums[i..j]</code> 表示 <code>nums</code> 中所有下标在 <code>i</code> 到 <code>j</code> 范围内的元素构成的子数组(满足 <code>0 <= i <= j < nums.length</code> ),那么我们称子数组 <code>nums[i..j]</code> 中不同值的数目为 <code>nums[i..j]</code> 的不同计数。</li>
|
||||
</ul>
|
||||
|
||||
<p>请你返回 <code>nums</code> 中所有子数组的 <strong>不同计数</strong> 的 <strong>平方</strong> 和。</p>
|
||||
|
||||
<p>由于答案可能会很大,请你将它对 <code>10<sup>9</sup> + 7</code> <strong>取余</strong> 后返回。</p>
|
||||
|
||||
<p>子数组指的是一个数组里面一段连续 <strong>非空</strong> 的元素序列。</p>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong class="example">示例 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>nums = [1,2,1]
|
||||
<b>输出:</b>15
|
||||
<b>解释:</b>六个子数组分别为:
|
||||
[1]: 1 个互不相同的元素。
|
||||
[2]: 1 个互不相同的元素。
|
||||
[1]: 1 个互不相同的元素。
|
||||
[1,2]: 2 个互不相同的元素。
|
||||
[2,1]: 2 个互不相同的元素。
|
||||
[1,2,1]: 2 个互不相同的元素。
|
||||
所有不同计数的平方和为 1<sup>2</sup> + 1<sup>2</sup> + 1<sup>2</sup> + 2<sup>2</sup> + 2<sup>2</sup> + 2<sup>2</sup> = 15 。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 2:</strong></p>
|
||||
|
||||
<pre>
|
||||
<b>输入:</b>nums = [2,2]
|
||||
<b>输出:3</b>
|
||||
<strong>解释:</strong>三个子数组分别为:
|
||||
[2]: 1 个互不相同的元素。
|
||||
[2]: 1 个互不相同的元素。
|
||||
[2,2]: 1 个互不相同的元素。
|
||||
所有不同计数的平方和为 1<sup>2</sup> + 1<sup>2</sup> + 1<sup>2</sup> = 3 。
|
||||
</pre>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>提示:</strong></p>
|
||||
|
||||
<ul>
|
||||
<li><code>1 <= nums.length <= 10<sup>5</sup></code></li>
|
||||
<li><code>1 <= nums[i] <= 10<sup>5</sup></code></li>
|
||||
</ul>
|
@@ -0,0 +1,50 @@
|
||||
<p>给你一个下标从 <strong>0</strong> 开始的整数数组 <code>nums</code> 和一个整数 <code>k</code> 。</p>
|
||||
|
||||
<p><code>nums</code> 中的 <strong>K-or</strong> 是一个满足以下条件的非负整数:</p>
|
||||
|
||||
<ul>
|
||||
<li>只有在 <code>nums</code> 中,至少存在 <code>k</code> 个元素的第 <code>i</code> 位值为 1 ,那么 K-or 中的第 <code>i</code> 位的值才是 1 。</li>
|
||||
</ul>
|
||||
|
||||
<p>返回 <code>nums</code> 的 <strong>K-or</strong> 值。</p>
|
||||
|
||||
<p><strong>注意</strong> :对于整数 <code>x</code> ,如果 <code>(2<sup>i</sup> AND x) == 2<sup>i</sup></code> ,则 <code>x</code> 中的第 <code>i</code> 位值为 1 ,其中 <code>AND</code> 为按位与运算符。</p>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong class="example">示例 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>nums = [7,12,9,8,9,15], k = 4
|
||||
<strong>输出:</strong>9
|
||||
<strong>解释:</strong>nums[0]、nums[2]、nums[4] 和 nums[5] 的第 0 位的值为 1 。
|
||||
nums[0] 和 nums[5] 的第 1 位的值为 1 。
|
||||
nums[0]、nums[1] 和 nums[5] 的第 2 位的值为 1 。
|
||||
nums[1]、nums[2]、nums[3]、nums[4] 和 nums[5] 的第 3 位的值为 1 。
|
||||
只有第 0 位和第 3 位满足数组中至少存在 k 个元素在对应位上的值为 1 。因此,答案为 2^0 + 2^3 = 9 。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 2:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>nums = [2,12,1,11,4,5], k = 6
|
||||
<strong>输出:</strong>0
|
||||
<strong>解释:</strong>因为 k == 6 == nums.length ,所以数组的 6-or 等于其中所有元素按位与运算的结果。因此,答案为 2 AND 12 AND 1 AND 11 AND 4 AND 5 = 0 。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 3:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>nums = [10,8,5,9,11,6,8], k = 1
|
||||
<strong>输出:</strong>15
|
||||
<strong>解释:</strong>因为 k == 1 ,数组的 1-or 等于其中所有元素按位或运算的结果。因此,答案为 10 OR 8 OR 5 OR 9 OR 11 OR 6 OR 8 = 15 。</pre>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>提示:</strong></p>
|
||||
|
||||
<ul>
|
||||
<li><code>1 <= nums.length <= 50</code></li>
|
||||
<li><code>0 <= nums[i] < 2<sup>31</sup></code></li>
|
||||
<li><code>1 <= k <= nums.length</code></li>
|
||||
</ul>
|
@@ -0,0 +1,50 @@
|
||||
<p>有一棵由 <code>n</code> 个节点组成的无向树,以 <code>0</code> 为根节点,节点编号从 <code>0</code> 到 <code>n - 1</code> 。给你一个长度为 <code>n - 1</code> 的二维 <strong>整数</strong> 数组 <code>edges</code> ,其中 <code>edges[i] = [a<sub>i</sub>, b<sub>i</sub>]</code> 表示在树上的节点 <code>a<sub>i</sub></code> 和 <code>b<sub>i</sub></code> 之间存在一条边。另给你一个下标从 <strong>0</strong> 开始、长度为 <code>n</code> 的数组 <code>coins</code> 和一个整数 <code>k</code> ,其中 <code>coins[i]</code> 表示节点 <code>i</code> 处的金币数量。</p>
|
||||
|
||||
<p>从根节点开始,你必须收集所有金币。要想收集节点上的金币,必须先收集该节点的祖先节点上的金币。</p>
|
||||
|
||||
<p>节点 <code>i</code> 上的金币可以用下述方法之一进行收集:</p>
|
||||
|
||||
<ul>
|
||||
<li>收集所有金币,得到共计 <code>coins[i] - k</code> 点积分。如果 <code>coins[i] - k</code> 是负数,你将会失去 <code>abs(coins[i] - k)</code> 点积分。</li>
|
||||
<li>收集所有金币,得到共计 <code>floor(coins[i] / 2)</code> 点积分。如果采用这种方法,节点 <code>i</code> 子树中所有节点 <code>j</code> 的金币数 <code>coins[j]</code> 将会减少至 <code>floor(coins[j] / 2)</code> 。</li>
|
||||
</ul>
|
||||
|
||||
<p>返回收集 <strong>所有</strong> 树节点的金币之后可以获得的最大积分。</p>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong class="example">示例 1:</strong></p>
|
||||
<img alt="" src="https://assets.leetcode.com/uploads/2023/09/18/ex1-copy.png" style="width: 60px; height: 316px; padding: 10px; background: rgb(255, 255, 255); border-radius: 0.5rem;" />
|
||||
<pre>
|
||||
<strong>输入:</strong>edges = [[0,1],[1,2],[2,3]], coins = [10,10,3,3], k = 5
|
||||
<strong>输出:</strong>11
|
||||
<strong>解释:</strong>
|
||||
使用第一种方法收集节点 0 上的所有金币。总积分 = 10 - 5 = 5 。
|
||||
使用第一种方法收集节点 1 上的所有金币。总积分 = 5 + (10 - 5) = 10 。
|
||||
使用第二种方法收集节点 2 上的所有金币。所以节点 3 上的金币将会变为 floor(3 / 2) = 1 ,总积分 = 10 + floor(3 / 2) = 11 。
|
||||
使用第二种方法收集节点 3 上的所有金币。总积分 = 11 + floor(1 / 2) = 11.
|
||||
可以证明收集所有节点上的金币能获得的最大积分是 11 。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 2:</strong></p>
|
||||
<strong class="example"> <img alt="" src="https://assets.leetcode.com/uploads/2023/09/18/ex2.png" style="width: 140px; height: 147px; padding: 10px; background: #fff; border-radius: .5rem;" /></strong>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>edges = [[0,1],[0,2]], coins = [8,4,4], k = 0
|
||||
<strong>输出:</strong>16
|
||||
<strong>解释:</strong>
|
||||
使用第一种方法收集所有节点上的金币,因此,总积分 = (8 - 0) + (4 - 0) + (4 - 0) = 16 。
|
||||
</pre>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>提示:</strong></p>
|
||||
|
||||
<ul>
|
||||
<li><code>n == coins.length</code></li>
|
||||
<li><code>2 <= n <= 10<sup>5</sup></code></li>
|
||||
<li><code><font face="monospace">0 <= coins[i] <= 10<sup>4</sup></font></code></li>
|
||||
<li><code>edges.length == n - 1</code></li>
|
||||
<li><code><font face="monospace">0 <= edges[i][0], edges[i][1] < n</font></code></li>
|
||||
<li><code><font face="monospace">0 <= k <= 10<sup>4</sup></font></code></li>
|
||||
</ul>
|
@@ -0,0 +1,35 @@
|
||||
<p>给你两个由正整数和 <code>0</code> 组成的数组 <code>nums1</code> 和 <code>nums2</code> 。</p>
|
||||
|
||||
<p>你必须将两个数组中的<strong> 所有</strong> <code>0</code> 替换为 <strong>严格</strong> 正整数,并且满足两个数组中所有元素的和 <strong>相等</strong> 。</p>
|
||||
|
||||
<p>返回 <strong>最小</strong> 相等和 ,如果无法使两数组相等,则返回 <code>-1</code><em> </em>。</p>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong class="example">示例 1:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>nums1 = [3,2,0,1,0], nums2 = [6,5,0]
|
||||
<strong>输出:</strong>12
|
||||
<strong>解释:</strong>可以按下述方式替换数组中的 0 :
|
||||
- 用 2 和 4 替换 nums1 中的两个 0 。得到 nums1 = [3,2,2,1,4] 。
|
||||
- 用 1 替换 nums2 中的一个 0 。得到 nums2 = [6,5,1] 。
|
||||
两个数组的元素和相等,都等于 12 。可以证明这是可以获得的最小相等和。
|
||||
</pre>
|
||||
|
||||
<p><strong class="example">示例 2:</strong></p>
|
||||
|
||||
<pre>
|
||||
<strong>输入:</strong>nums1 = [2,0,2,0], nums2 = [1,4]
|
||||
<strong>输出:</strong>-1
|
||||
<strong>解释:</strong>无法使两个数组的和相等。
|
||||
</pre>
|
||||
|
||||
<p> </p>
|
||||
|
||||
<p><strong>提示:</strong></p>
|
||||
|
||||
<ul>
|
||||
<li><code>1 <= nums1.length, nums2.length <= 10<sup>5</sup></code></li>
|
||||
<li><code>0 <= nums1[i], nums2[i] <= 10<sup>6</sup></code></li>
|
||||
</ul>
|
Reference in New Issue
Block a user