# include<bits/stdc++.h>
using namespace std;
const int N = 30005;
int a[N];
int main(){
int n, k, x;
cin >> n;
for(int i = 1; i <= n; i++){
cin >> x;
a[x]++;
}
int s = 0;
for(int i = 1; i <= N; i++){
if(a[i] > 0) s++;
if(s == k){
cout << i;
return 0;
}
}
cout << "NO RESULT";
return 0;
}