| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 54650 | 石利伟 | 第k小整数 | C++ | Accepted | 100 | 1 MS | 344 KB | 281 | 2022-07-29 16:40:03 |
#include <bits/stdc++.h> using namespace std; int n,k,op=0; int a[10000],fi[10000]={0}; int main(){ cin>>n>>k; for(int i=1;i<=n;i++){ int t; cin>>t; if(fi[t]==0)a[++op]=t,fi[t]=1; } sort(a,a+op+1); if(k>op)cout<<"NO RESULT"; else cout<<a[k]; return 0; }