| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 54602 | 孙喻桐 | 第k小整数 | C++ | Runtime Error | 0 | 0 MS | 256 KB | 328 | 2022-07-29 16:31:19 |
#include<bits/stdc++.h> using namespace std; int a[10001],k,n,b[10001],c[10001],m; int main(){ cin>>n>>k; for(int i=1;i<=n;i++){ cin>>a[i]; } m=n; while(m--){ b[a[m]]++; } int ans; for(int i=1;i<=10001;i++){ if(b[i]>0)c[ans++]=i; } if(k<=ans)cout<<c[k]; else cout<<"NO RESULT"; return 0; }