mirror of
https://gitee.com/coder-xiaomo/leetcode-problemset
synced 2025-01-10 18:48:13 +08:00
22 lines
568 B
HTML
22 lines
568 B
HTML
<p>设备中存有 <code>n</code> 个文件,文件 <code>id</code> 记于数组 <code>documents</code>。若文件 <code>id</code> 相同,则定义为该文件存在副本。请返回任一存在副本的文件 <code>id</code>。</p>
|
||
|
||
<p> </p>
|
||
|
||
<p><strong>示例 1:</strong></p>
|
||
|
||
<pre>
|
||
<strong>输入:</strong>documents = [2, 5, 3, 0, 5, 0]
|
||
<strong>输出:</strong>0 或 5
|
||
</pre>
|
||
|
||
<p> </p>
|
||
|
||
<p><strong>提示:</strong></p>
|
||
|
||
<ul>
|
||
<li><code>0 ≤ documents[i] ≤ n-1</code></li>
|
||
<li><code>2 <= n <= 100000</code></li>
|
||
</ul>
|
||
|
||
<p> </p>
|