564. Practice Session on Array
0
Easy
Olivia's teacher decided to take question practice session on Arrays. So, she was given an integer array arr, now the task is to print true if any value appears at least twice in the array, and print false if every element is distinct.
Input Format
First Line contains size of Array
Second Line contains elements of array
Second Line contains elements of array
Output Format
Print true or false.
Example
Input
4
1 2 3 1
Output
true
Constraints
1 <= arr.length <= 105
-109 <= arr[i] <= 109
-109 <= arr[i] <= 109
Loading...
View Submissions
Console