Top Earners

  • + 27 comments

    MySQL solution

    From my HackerRank solutions.

    SELECT salary * months AS earnings, COUNT(*)
    FROM Employee
    GROUP BY earnings
    ORDER BY earnings DESC
    LIMIT 1;
    

    Let me know if you have any questions.