Reddit Interview Question

SQL queries with window functions