18. Find H-Index
β GFG solution to the Find H-Index problem: calculate researcher's h-index using optimal bucket counting technique with linear time complexity. π
π§© Problem Description
π Examples
Example 1
Input: citations[] = [3, 0, 5, 3, 0]
Output: 3
Explanation: There are at least 3 papers with citation counts of 3, 5, and 3,
all having citations greater than or equal to 3.Example 2
Input: citations[] = [5, 1, 2, 4, 1]
Output: 2
Explanation: There are 3 papers (with citation counts of 5, 2, and 4) that have 2 or more citations.
However, the H-Index cannot be 3 because there aren't 3 papers with 3 or more citations.Example 3
π Constraints
β
My Approach
Bucket Counting Approach
π Time and Auxiliary Space Complexity
π§ Code (C)
π§βπ» Code (C++)
β Code (Java)
π Code (Python)
π§ Contribution and Support
πVisitor Count
Last updated