Solve real aggregation problems against the clock. Earn points, maintain daily streaks, and climb the leaderboard.
Find posts with more than 500 likes. Return only the authorName, content (first 50 chars is fine), likes, and shares fields. Sort by likes descending.
Group all orders by their status field. Return each status with the count of orders. Sort by count descending.
Find the average salary for each department. Return department name and average salary rounded to nearest dollar. Sort by average salary descending.
Unwind the items array from orders. For each product, calculate total quantity sold and total revenue. Only include delivered orders. Sort by revenue descending, limit to top 5.
Group employees by whether they work remotely (location.remote field). For each group, show count, average salary, and min/max salary. Include a field called `workStyle` with value 'Remote' or 'Office'.
Calculate an engagement rate for each author: (likes + comments + shares) / views * 100. Group posts by authorName, compute average engagement rate across all their posts. Return top 3 authors by engagement rate, rounded to 2 decimal places.
Build a single aggregation using $facet that simultaneously returns: (1) `statusBreakdown` — order count per status, (2) `cityRevenue` — top 3 cities by total revenue, (3) `summary` — total orders and grand total revenue as a single document.