| Run ID | Author | Problem | Lang | Verdict | Score | Time | Memory | Code Length | Submit Time |
|---|---|---|---|---|---|---|---|---|---|
| 55611 | 汪天一 | 第k小整数 | C++ | Accepted | 100 | 1 MS | 292 KB | 354 | 2022-07-30 16:37:02 |
#include<bits/stdc++.h> using namespace std; const int MAX = 10001; int a[MAX] = {0}; int main(){ int n, x, k; cin >> n >> k; for(int i = 1; i <= n; i++){ cin >> x; a[x]++; } for(int i = 0;i <= 10000; i++){ if(a[i] != 0) { k--; if(k == 0){ cout << i; return 0; } } } cout << "NO RESULT"; return 0; }