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

add leetcode problem-cn part5

This commit is contained in:
2022-03-27 20:52:13 +08:00
parent 053330914a
commit c11d601602
326 changed files with 26353 additions and 0 deletions

View File

@@ -0,0 +1,24 @@
<p>给定一个数组&nbsp;<code>nums</code>&nbsp;,如果&nbsp;<code>i &lt; j</code>&nbsp;&nbsp;<code>nums[i] &gt; 2*nums[j]</code>&nbsp;我们就将&nbsp;<code>(i, j)</code>&nbsp;称作一个<strong><em>重要翻转对</em></strong></p>
<p>你需要返回给定数组中的重要翻转对的数量。</p>
<p><strong>示例 1:</strong></p>
<pre>
<strong>输入</strong>: [1,3,2,3,1]
<strong>输出</strong>: 2
</pre>
<p><strong>示例 2:</strong></p>
<pre>
<strong>输入</strong>: [2,4,3,5,1]
<strong>输出</strong>: 3
</pre>
<p><strong>注意:</strong></p>
<ol>
<li>给定数组的长度不会超过<code>50000</code></li>
<li>输入数组中的所有数字都在32位整数的表示范围内。</li>
</ol>