class Solution {
public int hIndex(int[] citations) {
int n = citations.length;
Arrays.sort(citations);
int h = n;
while(h > 0){
if(citations[n-h] >= h) {
return h;
}
h--;
}
return 0;
}
}
01-31
683
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
06-28
127
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
07-13
355
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
08-22
458
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)
08-24
672
![](https://csdnimg.cn/release/blogv2/dist/pc/img/readCountWhite.png)