Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Commit 6aa138e

Browse files
committed
Added README.md file for Contains Duplicate
1 parent 96f43c2 commit 6aa138e

File tree

1 file changed

+20
-0
lines changed

1 file changed

+20
-0
lines changed

‎217-contains-duplicate/README.md

Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
<h2><a href="https://leetcode.com/problems/contains-duplicate">Contains Duplicate</a></h2> <img src='https://img.shields.io/badge/Difficulty-Easy-brightgreen' alt='Difficulty: Easy' /><hr><p>Given an integer array <code>nums</code>, return <code>true</code> if any value appears <strong>at least twice</strong> in the array, and return <code>false</code> if every element is distinct.</p>
2+
3+
<p>&nbsp;</p>
4+
<p><strong class="example">Example 1:</strong></p>
5+
<pre><strong>Input:</strong> nums = [1,2,3,1]
6+
<strong>Output:</strong> true
7+
</pre><p><strong class="example">Example 2:</strong></p>
8+
<pre><strong>Input:</strong> nums = [1,2,3,4]
9+
<strong>Output:</strong> false
10+
</pre><p><strong class="example">Example 3:</strong></p>
11+
<pre><strong>Input:</strong> nums = [1,1,1,3,3,4,3,2,4,2]
12+
<strong>Output:</strong> true
13+
</pre>
14+
<p>&nbsp;</p>
15+
<p><strong>Constraints:</strong></p>
16+
17+
<ul>
18+
<li><code>1 &lt;= nums.length &lt;= 10<sup>5</sup></code></li>
19+
<li><code>-10<sup>9</sup> &lt;= nums[i] &lt;= 10<sup>9</sup></code></li>
20+
</ul>

0 commit comments

Comments
(0)

AltStyle によって変換されたページ (->オリジナル) /