标签归档:leetcode

RSS feed of leetcode

[LeetCode]H-Index II

题目描述:

Follow up for H-Index: What if the citations array is sorted in ascending order? Could you optimize your algorithm?

Hint:

Expected runtime complexity is in O(log n) and the input is sorted.

题目大意:

H-Index的延伸:如果引用数组是递增有序的,你应该怎样优化算法?

提示:

期望运行时间复杂度为O ...

继续阅读