Majority Element
Very easy
Execution time limit is 1 second
Runtime memory usage limit is 128 megabytes
Given an array of size , find the majority element. The majority element is the element that appears more than times.
Input
The first line contains number . The second line contains positive integers.
Output
If the array contains majority element, then print it. Otherwise print .
Examples
Input #1
Answer #1
Input #2
Answer #2
Submissions 14K
Acceptance rate 41%