Contains Duplicate

Easy · Hashing · about 5 minutes

Asked at Amazon, Microsoft, Meta, Bloomberg, Google, Apple.

Report whether nums holds any repeated value. Return true if some value shows up two or more times, and false when all the values are different.

Related guides