Loading...

Best Day for Ad Revenue

A medium SQL interview practice problem on DataDriven. Write and execute real sql code with instant grading.

Domain
SQL
Difficulty
medium
Seniority
senior

Problem

The ad team wants to identify which day of the month shows the strongest click premium: the biggest gap between average revenue on clicked impressions versus non-clicked ones. For each calendar day (1 through 31), compute the overall average revenue and the peak single-impression revenue. Return only the one day where the click premium is widest.

Practice This Problem

Solve this SQL problem with real code execution. DataDriven runs your SQL queries against a live PostgreSQL database and grades it instantly.