Skip to content
Avio Lines
Q2

Aggregation & GROUP BY

45 stations · 6.4h

COUNT, SUM, AVG with GROUP BY and HAVING, ratios and percentages. 45 interview problems explained by Everyday Data Science (6.4h of video), grouped into 3 patterns such as Ratios & percentages, Filter groups with HAVING, Count & sum per group.

Start this line →
problems by zone (pattern)
  • Ratios & percentages10
  • Filter groups with HAVING8
  • Count & sum per group12
  • Other19
  1. Ratios & percentages

    0 of 10 passed
  2. EasyGoogle · Amazon · +3 more companiesLeetCode ↗ (opens in a new tab)
  3. Average Selling PriceLC 1251 · 17:11
    EasyGoogle · Amazon · +4 more companiesLeetCode ↗ (opens in a new tab)
  4. EasyGoogle · Amazon · +5 more companiesLeetCode ↗ (opens in a new tab)
  5. Confirmation RateLC 1934 · 11:47
    MediumGoogle · Amazon · +3 more companiesLeetCode ↗ (opens in a new tab)
  6. Get Highest Answer Rate QuestionLC 578 · 9:18 · LeetCode Premium
    MediumMetaLeetCode ↗ (opens in a new tab)
  7. Calculate Compressed MeanLC 2985 · 2:14 · LeetCode Premium
    EasyGoogleLeetCode ↗ (opens in a new tab)
  8. Reported Posts IILC 1132 · 9:23 · LeetCode Premium
    MediumMetaLeetCode ↗ (opens in a new tab)
  9. Filter groups with HAVING

    0 of 8 passed
  10. EasyGoogle · Amazon · +2 more companiesLeetCode ↗ (opens in a new tab)
  11. EasyGoogle · Microsoft · +1 more companiesLeetCode ↗ (opens in a new tab)
  12. Loan TypesLC 2990 · 3:26 · LeetCode Premium
    EasyGoogleLeetCode ↗ (opens in a new tab)
  13. Find Top Scoring StudentsLC 3182 · 9:33 · LeetCode Premium
    MediumLeetCode ↗ (opens in a new tab)
  14. Count & sum per group

    0 of 12 passed
  15. EasyGoogle · Amazon · +2 more companiesLeetCode ↗ (opens in a new tab)
  16. Number of Comments per PostLC 1241 · 15:09 · LeetCode Premium
    EasyMetaLeetCode ↗ (opens in a new tab)
  17. EasyGoogle · Amazon · +1 more companiesLeetCode ↗ (opens in a new tab)
  18. The Number of Rich CustomersLC 2082 · 3:54 · LeetCode Premium
    EasyathenahealthLeetCode ↗ (opens in a new tab)
  19. EasyGoogle · Amazon · +3 more companiesLeetCode ↗ (opens in a new tab)
  20. Find Followers CountLC 1729 · 3:54
    EasyGoogle · Amazon · +3 more companiesLeetCode ↗ (opens in a new tab)
  21. EasyGoogle · Amazon · +2 more companiesLeetCode ↗ (opens in a new tab)
  22. Loan TypesLC 2990 · 3:26 · LeetCode Premium
    EasyGoogleLeetCode ↗ (opens in a new tab)
  23. Calculate Compressed MeanLC 2985 · 2:14 · LeetCode Premium
    EasyGoogleLeetCode ↗ (opens in a new tab)
  24. Count Occurrences in TextLC 2738 · 4:25 · LeetCode Premium
    MediumLeetCode ↗ (opens in a new tab)
  25. Other

    0 of 19 passed
  26. Duplicate EmailsLC 182 · 6:27
    EasyGoogle · Amazon · +5 more companiesLeetCode ↗ (opens in a new tab)
  27. Reported PostsLC 1113 · 6:59 · LeetCode Premium
    EasyMetaLeetCode ↗ (opens in a new tab)
  28. Product Sales Analysis IILC 1069 · 3:17 · LeetCode Premium
    EasyAmazonLeetCode ↗ (opens in a new tab)
  29. Game Play Analysis ILC 511 · 3:38
    EasyGoogle · Amazon · +4 more companiesLeetCode ↗ (opens in a new tab)
  30. Project Employees ILC 1075 · 4:31
    EasyGoogle · Amazon · +4 more companiesLeetCode ↗ (opens in a new tab)
  31. League StatisticsLC 1841 · 18:56 · LeetCode Premium
    MediumLeetCode ↗ (opens in a new tab)
  32. Sales Analysis IIILC 1084 · 8:15
    EasyGoogle · Amazon · +1 more companiesLeetCode ↗ (opens in a new tab)
  33. Product Sales Analysis VLC 2329 · 7:06 · LeetCode Premium
    EasyAmazonLeetCode ↗ (opens in a new tab)
  34. Bank Account SummaryLC 1555 · 13:48 · LeetCode Premium
    MediumOptumLeetCode ↗ (opens in a new tab)
  35. Article Views IILC 1149 · 6:21 · LeetCode Premium
    MediumLinkedInLeetCode ↗ (opens in a new tab)
  36. Bikes Last Time UsedLC 2687 · 3:03 · LeetCode Premium
    EasyLeetCode ↗ (opens in a new tab)
  37. Find Latest SalariesLC 2668 · 3:55 · LeetCode Premium
    EasyLeetCode ↗ (opens in a new tab)

All 45 stations in order

  1. 1.Duplicate Emails (LeetCode 182)
  2. 2.Customer Placing the Largest Number of Orders (LeetCode 586)
  3. 3.Classes With at Least 5 Students (LeetCode 596)
  4. 4.Actors and Directors Who Cooperated At Least Three Times (LeetCode 1050)
  5. 5.Reported Posts (LeetCode 1113)
  6. 6.Queries Quality and Percentage (LeetCode 1211)
  7. 7.Number of Comments per Post (LeetCode 1241)
  8. 8.Average Selling Price (LeetCode 1251)
  9. 9.Bank Account Summary II (LeetCode 1587)
  10. 10.Daily Leads and Partners (LeetCode 1693)
  11. 11.Find Total Time Spent by Each Employee (LeetCode 1741)
  12. 12.The Number of Rich Customers (LeetCode 2082)
  13. 13.Product Sales Analysis II (LeetCode 1069)
  14. 14.Game Play Analysis I (LeetCode 511)
  15. 15.Primary Department for Each Employee (LeetCode 1789)
  16. 16.Find Followers Count (LeetCode 1729)
  17. 17.Percentage of Users Attended a Contest (LeetCode 1633)
  18. 18.Confirmation Rate (LeetCode 1934)
  19. 19.Orders With Maximum Quantity Above Average (LeetCode 1867)
  20. 20.Project Employees I (LeetCode 1075)
  21. 21.League Statistics (LeetCode 1841)
  22. 22.Average Salary: Departments VS Company (LeetCode 615)
  23. 23.Sales Analysis III (LeetCode 1084)
  24. 24.Number of Unique Subjects Taught by Each Teacher (LeetCode 2356)
  25. 25.Product Sales Analysis V (LeetCode 2329)
  26. 26.Get Highest Answer Rate Question (LeetCode 578)
  27. 27.Friend Requests I: Overall Acceptance Rate (LeetCode 597)
  28. 28.Bank Account Summary (LeetCode 1555)
  29. 29.Article Views II (LeetCode 1149)
  30. 30.Find Candidates for Data Scientist Position (LeetCode 3051)
  31. 31.Loan Types (LeetCode 2990)
  32. 32.Calculate Compressed Mean (LeetCode 2985)
  33. 33.Highest Salaries Difference (LeetCode 2853)
  34. 34.Bikes Last Time Used (LeetCode 2687)
  35. 35.Find Latest Salaries (LeetCode 2668)
  36. 36.Reported Posts II (LeetCode 1132)
  37. 37.Count Occurrences in Text (LeetCode 2738)
  38. 38.Find Candidates for Data Scientist Position II (LeetCode 3278)
  39. 39.Find Top Scoring Students (LeetCode 3182)
  40. 40.Find Top Scoring Students II (LeetCode 3188)
  41. 41.Customer Purchasing Behavior Analysis (LeetCode 3230)
  42. 42.Analyze Subscription Conversion (LeetCode 3497)
  43. 43.Find Books with Polarized Opinions (LeetCode 3642)
  44. 44.Find Stores with Inventory Imbalance (LeetCode 3626)
  45. 45.Find Users with High Token Usage (LeetCode 3793)