---
title: "Discussion on \"LeetCode #217: Contains Duplicate\" | Hashnode"
description: "Discussion on \"LeetCode #217: Contains Duplicate\". Question\nGiven an integer array nums, return true if any value appears at least twice in the array, and return false if every element is distinct.\nExamples\nInput: nums = [1,2,3,1]\nOutput: true\n\nInput: nums = [1,2,3,4]\nOutput: false\n\nInput: nums = [1,..."
url: "https://hashnode.com/posts/leetcode-217-contains-duplicate/64225b2d72b41f37ad2406a0"
---

[Feed](https://hashnode.com/feed) /

Discussion

# [LeetCode #217: Contains Duplicate](https://stephensun.hashnode.dev/leetcode-217-contains-duplicate?utm_source=hashnode&utm_medium=feed)

Question Given an integer array nums, return true if any value appears at least twice in the array, and return false if every element is distinct. Examples Input: nums = \[1,2,3,1\] Output: true Input: nums = \[1,2,3,4\] Output: false Input: nums = \[1,...

Mar 28, 2023 · 3 min read · stephensun.hashnode.dev  
Read the article

-   [#javascript](https://hashnode.com/tag/javascript)
-   [#data-structures](https://hashnode.com/tag/data-structures)

## Written by

[Stephen Sun](https://hashnode.com/@stephensun)

@stephensun · Houston, Texas

  
[View profile](https://hashnode.com/@stephensun)

Software Architect @ Eleox

## Responses

Markdown supported · ⌘↵ to post

No responses yet.
