#include <string>
#include <vector>
#include <algorithm>
using namespace std;
int solution(vector<int> citations) {
int max = 0,front = 0;
int n = citations.size();
sort(citations.begin(), citations.end());
for(int i=0;i<citations[n-1];i++){
if(citations[front+1]<i)
front++;
if(n-front-1>=i)
max = i;
}
return max;
}
top of page
실제 작동 상태를 확인하려면 라이브 사이트로 이동하세요.
H-index(미완)
H-index(미완)
댓글 0개
좋아요
댓글(0)
bottom of page